mirror of
https://github.com/godotengine/godot.git
synced 2025-12-08 06:09:55 +00:00
Fix forcing ViewportTexture after selecting a viewport in the "Pick a Viewport" popup
This popup only pops up when a `ViewportTexture` (or its derived class) object is **just** assigned.
This commit is contained in:
parent
134da37497
commit
5257f3e770
1 changed files with 3 additions and 2 deletions
|
|
@ -3228,8 +3228,9 @@ void EditorPropertyResource::_viewport_selected(const NodePath &p_path) {
|
|||
return;
|
||||
}
|
||||
|
||||
Ref<ViewportTexture> vt;
|
||||
vt.instantiate();
|
||||
Ref<ViewportTexture> vt = get_edited_property_value();
|
||||
ERR_FAIL_COND(vt.is_null());
|
||||
|
||||
vt->set_viewport_path_in_scene(get_tree()->get_edited_scene_root()->get_path_to(to_node));
|
||||
|
||||
emit_changed(get_edited_property(), vt);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue