Initialization order of Widget vs Bindings #53
jdaignault
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
We encountered an interesting scenario where we had the following setup:
Event Construct
was fetching aDynamic Material
from anImage
widget and cache it to a blueprint variableAs it turns out, when the binding executed for the first time, the cached variable turned out to be invalid. After poking around in
UUserWidget::NativeConstruct
, it was observed thatExtension->Construct
takes place before the widget'sConstruct
blueprint event.This scenario was easily fixed by moving the event graph logic to
Event PreConstruct
, but it raised a question about whether this initialization order seemed correct. Should bindings only try to initialize themselves only after widgets have 'fully initialized' themselves?Beta Was this translation helpful? Give feedback.
All reactions