add NULL as parent for MwReparent
All checks were successful
pyrite-dev/milsko/pipeline/head This commit looks good

This commit is contained in:
Nishi 2026-04-24 04:24:07 +09:00
commit 201c5f84a5
Signed by: nishi
GPG key ID: 27EF69B208EB9343

View file

@ -1018,9 +1018,11 @@ void MwReparent(MwWidget handle, MwWidget new_parent) {
}
handle->parent = new_parent;
arrput(new_parent->children, handle);
if(new_parent != NULL) {
arrput(new_parent->children, handle);
MwDispatch(handle->parent, children_update);
MwDispatch(handle->parent, children_update);
}
MwForceRender(handle);
}