Don't fire [component (parent-activated)] when the actor is still blocked (for #2)

This commit is contained in:
~keith 2021-12-14 22:16:42 +00:00
parent b3a6fd3f78
commit 46473ee8ce
Signed by: keith
GPG Key ID: 5BEBEEAB2C73D520
1 changed files with 6 additions and 5 deletions

View File

@ -151,11 +151,12 @@
(defmethod parent-activated ((this actor) parent)
"Called when the actor's parent is activated."
[this (recompute-blocked-p)]
(loop for child-ptr in [this children]
for child = (weak-pointer-value child-ptr)
do [child (parent-activated parent)])
(loop for component in [this components]
do [component (parent-activated parent)]))
(when [this tree-active-p]
(loop for child-ptr in [this children]
for child = (weak-pointer-value child-ptr)
do [child (parent-activated parent)])
(loop for component in [this components]
do [component (parent-activated parent)])))
(defmethod parent-changed ((this actor))
"Called when the actor's parent is changed."