ohos: share the sub window creation context
makeWindowProxyDataForSubWindowInJsThread() creates the sub window
with createSubWindowWithOptions() and falls back to createSubWindow()
when that is unavailable or fails. The second fallback runs in the
onCatch handler, after the onThen handler has already taken the
creation context by value, so nothing the fallback learns can reach
the rest of the creation.
Create the context before the creation promise and share it between
the handlers. This prepares for recording in the context whether the
fallback was taken. No change in behavior.
Task-number: QTBUG-151677
Change-Id: Id3c4e69b8b172731d7cc9bad0049b52b49700678
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>