summaryrefslogtreecommitdiff
path: root/client/widgets/radiobutton.cc
diff options
context:
space:
mode:
authordeva <deva>2008-06-30 11:47:05 +0000
committerdeva <deva>2008-06-30 11:47:05 +0000
commit1c190bfef95d9c48e10bd8e2168692c84b4b4558 (patch)
treecc1e73d3e34313be71cf523d2f8f6404403c55f5 /client/widgets/radiobutton.cc
parent5151bc32413efa8d34a21be21fa10f3bf62517c2 (diff)
Added setValue and cleaned up the code in general.
Diffstat (limited to 'client/widgets/radiobutton.cc')
-rw-r--r--client/widgets/radiobutton.cc12
1 files changed, 4 insertions, 8 deletions
diff --git a/client/widgets/radiobutton.cc b/client/widgets/radiobutton.cc
index 6de030d..b757828 100644
--- a/client/widgets/radiobutton.cc
+++ b/client/widgets/radiobutton.cc
@@ -27,7 +27,7 @@
#include "radiobutton.h"
#include <QRadioButton>
-RadioButton::RadioButton(QDomNode &node, bool radio_bool)
+RadioButton::RadioButton(QDomNode &node)
: QRadioButton()
{
QDomElement elem = node.toElement();
@@ -46,19 +46,15 @@ RadioButton::RadioButton(QDomNode &node, bool radio_bool)
setText("");
}
- if(radio_bool) {
- setChecked(true);
- } else setChecked(false);
-
if(elem.hasAttribute("value")) {
- radio_value = elem.attribute("value");
+ value = elem.attribute("value");
} else {
printf("XML ERROR!!! Radiobutton item has no value\n");
- radio_value = "none";
+ value = "none";
}
}
QString RadioButton::getValue()
{
- return radio_value;
+ return value;
}