mirror of
https://github.com/RGBCube/serenity
synced 2025-07-24 22:37:34 +00:00
VisualBuilder: Add GRadioButton to the widget repertoire.
This commit is contained in:
parent
b0d8dba16d
commit
40ca3b019f
4 changed files with 45 additions and 16 deletions
|
@ -1,18 +1,19 @@
|
|||
#include "VBWidget.h"
|
||||
#include "VBForm.h"
|
||||
#include "VBProperty.h"
|
||||
#include "VBWidgetRegistry.h"
|
||||
#include "VBWidget.h"
|
||||
#include "VBWidgetPropertyModel.h"
|
||||
#include <LibGUI/GPainter.h>
|
||||
#include <LibGUI/GLabel.h>
|
||||
#include "VBWidgetRegistry.h"
|
||||
#include <LibGUI/GButton.h>
|
||||
#include <LibGUI/GCheckBox.h>
|
||||
#include <LibGUI/GGroupBox.h>
|
||||
#include <LibGUI/GLabel.h>
|
||||
#include <LibGUI/GPainter.h>
|
||||
#include <LibGUI/GProgressBar.h>
|
||||
#include <LibGUI/GRadioButton.h>
|
||||
#include <LibGUI/GScrollBar.h>
|
||||
#include <LibGUI/GSlider.h>
|
||||
#include <LibGUI/GSpinBox.h>
|
||||
#include <LibGUI/GTextEditor.h>
|
||||
#include <LibGUI/GGroupBox.h>
|
||||
#include <LibGUI/GCheckBox.h>
|
||||
#include <LibGUI/GProgressBar.h>
|
||||
#include <LibGUI/GSlider.h>
|
||||
|
||||
VBWidget::VBWidget(VBWidgetType type, VBForm& form)
|
||||
: m_type(type)
|
||||
|
@ -161,9 +162,14 @@ void VBWidget::setup_properties()
|
|||
}
|
||||
|
||||
if (m_type == VBWidgetType::GCheckBox) {
|
||||
VB_ADD_PROPERTY(GCheckBox, "caption", text, set_text, string);
|
||||
VB_ADD_PROPERTY(GCheckBox, "text", text, set_text, string);
|
||||
VB_ADD_PROPERTY(GCheckBox, "checked", is_checked, set_checked, bool);
|
||||
}
|
||||
|
||||
if (m_type == VBWidgetType::GRadioButton) {
|
||||
VB_ADD_PROPERTY(GRadioButton, "text", text, set_text, string);
|
||||
VB_ADD_PROPERTY(GRadioButton, "checked", is_checked, set_checked, bool);
|
||||
}
|
||||
}
|
||||
|
||||
void VBWidget::synchronize_properties()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue