summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swift/QtUI/QtFormWidget.h')
-rw-r--r--Swift/QtUI/QtFormWidget.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/Swift/QtUI/QtFormWidget.h b/Swift/QtUI/QtFormWidget.h
index 2fb7b98..c7aae73 100644
--- a/Swift/QtUI/QtFormWidget.h
+++ b/Swift/QtUI/QtFormWidget.h
@@ -21,9 +21,12 @@ class QtFormWidget : public QWidget {
QtFormWidget(Form::ref form, QWidget* parent = NULL);
virtual ~QtFormWidget();
Form::ref getCompletedForm();
+ void setEditable(bool editable);
private:
QWidget* createWidget(FormField::ref field);
QListWidget* createList(FormField::ref field);
+ template<class T> void setEnabled(QWidget* rawWidget, bool editable);
+ template<class T> void setEditable(QWidget* rawWidget, bool editable);
std::map<std::string, QWidget*> fields_;
Form::ref form_;
};