(parent: Node | null, useMutator = false)
| 449 | } |
| 450 | |
| 451 | internalSetParent(parent: Node | null, useMutator = false) { |
| 452 | if (this._parent === parent) { |
| 453 | return |
| 454 | } |
| 455 | |
| 456 | if (this._parent) { |
| 457 | this._parent.children?.unlinkChild(this) |
| 458 | } |
| 459 | if (useMutator) { |
| 460 | this._parent?.didDropOut(this) |
| 461 | } |
| 462 | |
| 463 | if (parent) { |
| 464 | this._parent = parent |
| 465 | |
| 466 | if (useMutator) { |
| 467 | parent.didDropIn(this) |
| 468 | } |
| 469 | } |
| 470 | } |
| 471 | |
| 472 | internalUnlinkParent() { |
| 473 | this._parent = null |
no test coverage detected