diff options
author | Juan Linietsky <reduzio@gmail.com> | 2015-11-18 19:14:25 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2015-11-18 19:14:25 -0300 |
commit | a8f18e1bae63edcca6342b8e507585be6ba56d20 (patch) | |
tree | 206872dd8af2ad17782641202d555126548589f1 /tools/editor | |
parent | cba634c608a61d82e96073b7d6c42df24fb9f5b3 (diff) | |
parent | 6df7d923797908ecf38684c0008c0e4b6475d884 (diff) |
Merge pull request #2639 from MarianoGnu/origin
Fix ButtonGroup broken layout
Diffstat (limited to 'tools/editor')
-rw-r--r-- | tools/editor/plugins/theme_editor_plugin.cpp | 38 |
1 files changed, 18 insertions, 20 deletions
diff --git a/tools/editor/plugins/theme_editor_plugin.cpp b/tools/editor/plugins/theme_editor_plugin.cpp index 55e8f164d6..63ba57bfc0 100644 --- a/tools/editor/plugins/theme_editor_plugin.cpp +++ b/tools/editor/plugins/theme_editor_plugin.cpp @@ -568,26 +568,24 @@ ThemeEditor::ThemeEditor() { CheckButton *cb = memnew( CheckButton ); cb->set_text("CheckButton"); first_vb->add_child(cb ); - CheckBox *cbx = memnew( CheckBox ); - cbx->set_text("CheckBox"); - first_vb->add_child(cbx ); - - /* TODO: This is not working properly, controls are overlapping*/ - /* - ButtonGroup *bg = memnew( ButtonGroup ); - bg->set_v_size_flags(SIZE_EXPAND_FILL); - VBoxContainer *gbvb = memnew( VBoxContainer ); - gbvb->set_v_size_flags(SIZE_EXPAND_FILL); - CheckBox *rbx1 = memnew( CheckBox ); - rbx1->set_text("CheckBox Radio1"); - rbx1->set_pressed(true); - gbvb->add_child(rbx1); - CheckBox *rbx2 = memnew( CheckBox ); - rbx2->set_text("CheckBox Radio2"); - gbvb->add_child(rbx2); - bg->add_child(gbvb); - first_vb->add_child(bg); - */ + CheckBox *cbx = memnew( CheckBox ); + cbx->set_text("CheckBox"); + first_vb->add_child(cbx ); + + + ButtonGroup *bg = memnew( ButtonGroup ); + bg->set_v_size_flags(SIZE_EXPAND_FILL); + VBoxContainer *gbvb = memnew( VBoxContainer ); + gbvb->set_v_size_flags(SIZE_EXPAND_FILL); + CheckBox *rbx1 = memnew( CheckBox ); + rbx1->set_text("CheckBox Radio1"); + rbx1->set_pressed(true); + gbvb->add_child(rbx1); + CheckBox *rbx2 = memnew( CheckBox ); + rbx2->set_text("CheckBox Radio2"); + gbvb->add_child(rbx2); + bg->add_child(gbvb); + first_vb->add_child(bg); MenuButton* test_menu_button = memnew( MenuButton ); test_menu_button->set_text("MenuButton"); |