예제 #1
0
void KexiDBCheckBox::setValueInternal(const QVariant &add, bool removeOld)
{
	Q_UNUSED(add);
	Q_UNUSED(removeOld);
	if (isTristateInternal())
		setState( m_origValue.isNull() ? NoChange : (m_origValue.toBool() ? On : Off) );
	else
		setState( m_origValue.toBool() ? On : Off );
}
예제 #2
0
void KexiDBCheckBox::setValueInternal(const QVariant &add, bool removeOld)
{
    Q_UNUSED(add);
    Q_UNUSED(removeOld);
    if (isTristateInternal())
        setCheckState(m_origValue.isNull()
                      ? Qt::PartiallyChecked : (m_origValue.toBool() ? Qt::Checked : Qt::Unchecked));
    else
        setCheckState(m_origValue.toBool() ? Qt::Checked : Qt::Unchecked);
}