diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-02-28 11:24:19 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-28 11:24:19 +0100 |
commit | 9b7aeaf88fb9aab0c469b21a2058f17fdd4d8732 (patch) | |
tree | 048d250b9e355658381ec32a6431dd1c02de7b48 /scene/main/canvas_layer.cpp | |
parent | 0b7bc3fd907f3953cfebfbc8c8a0d245ac0e043c (diff) | |
parent | dce6cb7393ae20a2513a0e98c8e55399f27a4b05 (diff) |
Merge pull request #58413 from Sauermann/fix-canvas-item-visibility
Fix invisible CanvasItem visibility issue
Diffstat (limited to 'scene/main/canvas_layer.cpp')
-rw-r--r-- | scene/main/canvas_layer.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/scene/main/canvas_layer.cpp b/scene/main/canvas_layer.cpp index be24620904..7aa4d391f8 100644 --- a/scene/main/canvas_layer.cpp +++ b/scene/main/canvas_layer.cpp @@ -58,11 +58,7 @@ void CanvasLayer::set_visible(bool p_visible) { if (c) { RenderingServer::get_singleton()->canvas_item_set_visible(c->get_canvas_item(), p_visible && c->is_visible()); - if (c->is_visible()) { - c->_propagate_visibility_changed(p_visible); - } else { - c->parent_visible_in_tree = p_visible; - } + c->_propagate_visibility_changed(p_visible); } } } |