Merge pull request #56429 from PucklaMotzer09/tile_set_editor_hide

This commit is contained in:
Rémi Verschelde 2022-01-04 10:22:47 +01:00 committed by GitHub
commit 6994602e4f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 11 additions and 0 deletions

View File

@ -157,6 +157,17 @@ void TilesEditorPlugin::_update_editors() {
// Update the viewport. // Update the viewport.
CanvasItemEditor::get_singleton()->update_viewport(); CanvasItemEditor::get_singleton()->update_viewport();
// Update visibility of bottom panel buttons.
if (tileset_editor_button->is_pressed() && !tile_set.is_valid()) {
if (tile_map) {
editor_node->make_bottom_panel_item_visible(tilemap_editor);
} else {
editor_node->hide_bottom_panel();
}
}
tileset_editor_button->set_visible(tile_set.is_valid());
tilemap_editor_button->set_visible(tile_map);
} }
void TilesEditorPlugin::_notification(int p_what) { void TilesEditorPlugin::_notification(int p_what) {