diff options
author | senator <senator> | 2008-03-24 13:33:35 +0000 |
---|---|---|
committer | senator <senator> | 2008-03-24 13:33:35 +0000 |
commit | 917aea688614bd29568f7eb37efe8cbd2620b25c (patch) | |
tree | 568937b1a05890f5780500e5ae0696bd55cb1809 /client/widgets/combobox.cc | |
parent | 2e87c4608a9fb888fd7669756d8cb457ac305f71 (diff) |
Fixed isValid for combobox and radiobuttons
Diffstat (limited to 'client/widgets/combobox.cc')
-rw-r--r-- | client/widgets/combobox.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/client/widgets/combobox.cc b/client/widgets/combobox.cc index e60ea8e..29bf253 100644 --- a/client/widgets/combobox.cc +++ b/client/widgets/combobox.cc @@ -63,9 +63,14 @@ ComboBox::ComboBox(QDomNode node) if(default_found == 0) setCurrentIndex(-1); // -1 is default for none selected } +bool ComboBox::isValid() +{ + return currentIndex() != -1; +} + QString ComboBox::getValue() { - QString value = "none"; + QString value; if(currentIndex() != -1) value = itemData(currentIndex()).toString(); return value; } |