diff options
| author | Rémi Verschelde <rverschelde@gmail.com> | 2018-03-13 13:48:37 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-03-13 13:48:37 +0100 |
| commit | 535205196f10a4bb7bc9370f864139aa84cfd3d6 (patch) | |
| tree | a069ee255c624da66fbcdfb12850a33c8b4875d8 /editor/plugins/tile_map_editor_plugin.cpp | |
| parent | b1ae5ea4070d874ec2dc1dfb6f49512579afec9d (diff) | |
| parent | 2de1dfa42f821fcbc140d8ae8907c060135c584b (diff) | |
| download | redot-engine-535205196f10a4bb7bc9370f864139aa84cfd3d6.tar.gz | |
Merge pull request #17013 from Noshyaar/theme
Update icons when theme changed
Diffstat (limited to 'editor/plugins/tile_map_editor_plugin.cpp')
| -rw-r--r-- | editor/plugins/tile_map_editor_plugin.cpp | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/editor/plugins/tile_map_editor_plugin.cpp b/editor/plugins/tile_map_editor_plugin.cpp index c97e949403..8198d2422d 100644 --- a/editor/plugins/tile_map_editor_plugin.cpp +++ b/editor/plugins/tile_map_editor_plugin.cpp @@ -48,6 +48,20 @@ void TileMapEditor::_notification(int p_what) { } break; + case EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED: { + + bool new_show_tile_info = EditorSettings::get_singleton()->get("editors/tile_map/show_tile_info_on_hover"); + if (new_show_tile_info != show_tile_info) { + show_tile_info = new_show_tile_info; + tile_info->set_visible(show_tile_info); + } + + if (is_visible_in_tree()) { + _update_palette(); + } + + } // fallthrough + case NOTIFICATION_ENTER_TREE: { transp->set_icon(get_icon("Transpose", "EditorIcons")); @@ -61,19 +75,6 @@ void TileMapEditor::_notification(int p_what) { search_box->add_icon_override("right_icon", get_icon("Search", "EditorIcons")); } break; - - case EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED: { - - bool new_show_tile_info = EditorSettings::get_singleton()->get("editors/tile_map/show_tile_info_on_hover"); - if (new_show_tile_info != show_tile_info) { - show_tile_info = new_show_tile_info; - tile_info->set_visible(show_tile_info); - } - - if (is_visible_in_tree()) { - _update_palette(); - } - } break; } } |
