Add switch on hover to TabBar

This commit is contained in:
kobewi 2025-03-02 21:32:07 +01:00
parent c7b1767560
commit 682b0f7c54
12 changed files with 110 additions and 8 deletions

View file

@ -3027,6 +3027,11 @@ bool EditorPropertyNodePath::is_drop_valid(const Dictionary &p_drag_data) const
return false;
}
Object *data_root = p_drag_data.get("scene_root", (Object *)nullptr);
if (data_root && get_tree()->get_edited_scene_root() != data_root) {
return false;
}
Node *dropped_node = get_tree()->get_edited_scene_root()->get_node(nodes[0]);
ERR_FAIL_NULL_V(dropped_node, false);