Skip to content

Commit 09d6e0c

Browse files
committed
Make sure clicking AnimationTree node open the state machine editor not the track editor.
1 parent db66343 commit 09d6e0c

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

editor/plugins/animation_player_editor_plugin.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
#include "editor/gui/editor_file_dialog.h"
4242
#include "editor/gui/editor_validation_panel.h"
4343
#include "editor/inspector_dock.h"
44+
#include "editor/plugins/animation_tree_editor_plugin.h"
4445
#include "editor/plugins/canvas_item_editor_plugin.h" // For onion skinning.
4546
#include "editor/plugins/node_3d_editor_plugin.h" // For onion skinning.
4647
#include "editor/scene_tree_dock.h"
@@ -2409,6 +2410,10 @@ bool AnimationPlayerEditorPlugin::handles(Object *p_object) const {
24092410

24102411
void AnimationPlayerEditorPlugin::make_visible(bool p_visible) {
24112412
if (p_visible) {
2413+
// if AnimationTree editor is visible, do not occupy the bottom panel
2414+
if (AnimationTreeEditor::get_singleton() && AnimationTreeEditor::get_singleton()->is_visible_in_tree()) {
2415+
return;
2416+
}
24122417
EditorNode::get_bottom_panel()->make_item_visible(anim_editor);
24132418
anim_editor->set_process(true);
24142419
anim_editor->ensure_visibility();

0 commit comments

Comments
 (0)