X Tutup
Skip to content

Fix SplitContainer crash on change type#113164

Merged
akien-mga merged 1 commit intogodotengine:masterfrom
kitbdev:fix-spitcontainer-change-type-crash
Nov 26, 2025
Merged

Fix SplitContainer crash on change type#113164
akien-mga merged 1 commit intogodotengine:masterfrom
kitbdev:fix-spitcontainer-change-type-crash

Conversation

@kitbdev
Copy link
Contributor

@kitbdev kitbdev commented Nov 25, 2025

The crash was happening because _update_draggers expects to never be called if there is 0 or 1 valid children, but it is deferred so it can be.

There is also errors printed about removing children that aren't children, so I added a check for that.

It looks like replacing nodes doesn't delete their internal children, but it does unparent them. I'm not sure if that behavior is correct, but I'll leave it to a future PR.

@kitbdev kitbdev requested a review from a team as a code owner November 25, 2025 21:19
@kitbdev kitbdev added this to the 4.6 milestone Nov 25, 2025
@akien-mga akien-mga merged commit ca366b5 into godotengine:master Nov 26, 2025
20 checks passed
@akien-mga
Copy link
Member

Thanks!

@kitbdev kitbdev deleted the fix-spitcontainer-change-type-crash branch November 26, 2025 23:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Changing type from SplitContainer to H/VSplitContainer crashes the editor

2 participants

X Tutup