summaryrefslogtreecommitdiff
path: root/editor/plugins/canvas_item_editor_plugin.cpp
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2017-07-18 18:14:23 +0200
committerGitHub <noreply@github.com>2017-07-18 18:14:23 +0200
commit9cf72d0ae174badab07b1461f576955725375046 (patch)
tree4386712fb6d3b1016170542242da807998dc61b3 /editor/plugins/canvas_item_editor_plugin.cpp
parentae80d57b319a67b0dad7544082fe1362a0c1d6da (diff)
parent337c1238b9a4da1c0ccb0547a1be370c4ac6a56c (diff)
Merge pull request #9700 from djrm/button_fixes
Fixed button flat behavior when not in normal state.
Diffstat (limited to 'editor/plugins/canvas_item_editor_plugin.cpp')
-rw-r--r--editor/plugins/canvas_item_editor_plugin.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp
index b059e63467..c8936c8c35 100644
--- a/editor/plugins/canvas_item_editor_plugin.cpp
+++ b/editor/plugins/canvas_item_editor_plugin.cpp
@@ -3386,6 +3386,7 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) {
key_loc_button = memnew(Button("loc"));
key_loc_button->set_toggle_mode(true);
+ key_loc_button->set_flat(true);
key_loc_button->set_pressed(true);
key_loc_button->set_focus_mode(FOCUS_NONE);
key_loc_button->add_color_override("font_color", Color(1, 0.6, 0.6));
@@ -3394,6 +3395,7 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) {
animation_hb->add_child(key_loc_button);
key_rot_button = memnew(Button("rot"));
key_rot_button->set_toggle_mode(true);
+ key_rot_button->set_flat(true);
key_rot_button->set_pressed(true);
key_rot_button->set_focus_mode(FOCUS_NONE);
key_rot_button->add_color_override("font_color", Color(1, 0.6, 0.6));
@@ -3402,12 +3404,14 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) {
animation_hb->add_child(key_rot_button);
key_scale_button = memnew(Button("scl"));
key_scale_button->set_toggle_mode(true);
+ key_scale_button->set_flat(true);
key_scale_button->set_focus_mode(FOCUS_NONE);
key_scale_button->add_color_override("font_color", Color(1, 0.6, 0.6));
key_scale_button->add_color_override("font_color_pressed", Color(0.6, 1, 0.6));
key_scale_button->connect("pressed", this, "_popup_callback", varray(ANIM_INSERT_SCALE));
animation_hb->add_child(key_scale_button);
key_insert_button = memnew(Button);
+ key_insert_button->set_flat(true);
key_insert_button->set_focus_mode(FOCUS_NONE);
key_insert_button->connect("pressed", this, "_popup_callback", varray(ANIM_INSERT_KEY));
key_insert_button->set_tooltip(TTR("Insert Keys"));