mirror of
https://github.com/Trensa-Organization/hy3.git
synced 2025-03-15 18:53:40 +01:00
Fix parent pointer corruption in intoGroup
This appears to be what caused group movement related segfaults.
This commit is contained in:
parent
43a4aa2b16
commit
f12993ecf0
1 changed files with 2 additions and 1 deletions
|
@ -355,12 +355,13 @@ Hy3Node* Hy3Node::removeFromParentRecursive() {
|
|||
Hy3Node* Hy3Node::intoGroup(Hy3GroupLayout layout) {
|
||||
this->layout->nodes.push_back({
|
||||
.parent = this,
|
||||
.data = this->data,
|
||||
.data = layout,
|
||||
.workspace_id = this->workspace_id,
|
||||
.layout = this->layout,
|
||||
});
|
||||
|
||||
auto* node = &this->layout->nodes.back();
|
||||
swapData(*this, *node);
|
||||
|
||||
this->data = layout;
|
||||
this->data.as_group.children.push_back(node);
|
||||
|
|
Loading…
Add table
Reference in a new issue