summaryrefslogtreecommitdiff
path: root/editor/plugins/canvas_item_editor_plugin.cpp
diff options
context:
space:
mode:
authorDaniel J. Ramirez <djrmuv@gmail.com>2017-01-22 22:40:43 -0600
committerRĂ©mi Verschelde <rverschelde@gmail.com>2017-04-27 08:04:57 +0200
commitf045efe007cffb87238ee519b7f33d710814ded7 (patch)
tree9cb7b21ee73cd6a184ef2b18daff6867b98062d8 /editor/plugins/canvas_item_editor_plugin.cpp
parent5993a5fac9a108297fc7909d1a38abac471d037d (diff)
Add new editor and default theme (WIP)
Diffstat (limited to 'editor/plugins/canvas_item_editor_plugin.cpp')
-rw-r--r--editor/plugins/canvas_item_editor_plugin.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp
index 1a533dce32..430a5adeb1 100644
--- a/editor/plugins/canvas_item_editor_plugin.cpp
+++ b/editor/plugins/canvas_item_editor_plugin.cpp
@@ -3123,6 +3123,7 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) {
editor_selection->connect("selection_changed", this, "update");
hb = memnew(HBoxContainer);
+ hb->add_style_override("bg", editor->get_gui_base()->get_stylebox("panel", "PanelContainer"));
add_child(hb);
hb->set_area_as_parent_rect();
@@ -3299,6 +3300,8 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) {
animation_hb->hide();
key_loc_button = memnew(Button("loc"));
+ key_loc_button = memnew(Button("loc"));
+ key_loc_button->set_flat(true);
key_loc_button->set_toggle_mode(true);
key_loc_button->set_pressed(true);
key_loc_button->set_focus_mode(FOCUS_NONE);
@@ -3307,6 +3310,7 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) {
key_loc_button->connect("pressed", this, "_popup_callback", varray(ANIM_INSERT_POS));
animation_hb->add_child(key_loc_button);
key_rot_button = memnew(Button("rot"));
+ key_rot_button->set_flat(true);
key_rot_button->set_toggle_mode(true);
key_rot_button->set_pressed(true);
key_rot_button->set_focus_mode(FOCUS_NONE);
@@ -3315,13 +3319,14 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) {
key_rot_button->connect("pressed", this, "_popup_callback", varray(ANIM_INSERT_ROT));
animation_hb->add_child(key_rot_button);
key_scale_button = memnew(Button("scl"));
+ key_scale_button->set_flat(true);
key_scale_button->set_toggle_mode(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 = memnew(ToolButton);
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"));