diff options
author | Rindbee <idleman@yeah.net> | 2022-08-14 19:17:45 +0800 |
---|---|---|
committer | RĂ©mi Verschelde <rverschelde@gmail.com> | 2023-05-12 12:31:22 +0200 |
commit | b91b8fce43ab9cb9f8c96f8c640acc801774b6b5 (patch) | |
tree | 3c3eb5511ddef46a86c6b5a305264630c47febfa /editor | |
parent | 1146172b302a68393e4f97b47e6460d78db75518 (diff) |
Improve the UX of ViewportTexture in the editor
The associated `ViewportTexture`s will update the `viewport_path`
in time when the `Viewport`'s nodepath is changed (caused by renaming
the node names or moving in the SceneTree dock).
If the target `Viewport` is changed by resetting the `viewport_path`,
the `ViewportTexture`s will be re-setup and emit `changed` signal in
time.
(cherry picked from commit af58f1e8547c8b6a2e6b83b7de9c3ac9bc05d881)
Diffstat (limited to 'editor')
-rw-r--r-- | editor/editor_properties.cpp | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/editor/editor_properties.cpp b/editor/editor_properties.cpp index 01a574def6..348e1ead4a 100644 --- a/editor/editor_properties.cpp +++ b/editor/editor_properties.cpp @@ -3998,7 +3998,6 @@ void EditorPropertyResource::_viewport_selected(const NodePath &p_path) { Ref<ViewportTexture> vt; vt.instantiate(); vt->set_viewport_path_in_scene(get_tree()->get_edited_scene_root()->get_path_to(to_node)); - vt->setup_local_to_scene(); emit_changed(get_edited_property(), vt); update_property(); |