When calling `Engine.PushGuiPage` a promise is returned. The promise is
settled when the "child" page is closed. That allows to `await` it
inside `async` functions.
Previously the callback was run right inside the call to
`Engine.PopGuiPage`. Now the continuation of the promise is called at
the end of the "tick".
This won't help performance. It will more likely make things worse.
Since gui pages aren't opened or closed that frequently, it doesn't
matter that much.
Refs: 86c151ebaa
For the engine side:
The promise is stored in the `CGUIManager::SGUIPage` (like previously
the callback). When the promise is fulfilled it enqueues a callback in
the `JobQueue` of the `JSContext`.
Original patch by: @wraitii
Comments by: @wraitii, @Stan, @Polakrity, @lyv, @elexis, @vladislavbelov
Differential Revision: https://code.wildfiregames.com/D3807
This was SVN commit r28145.
Summary:
Single-player is proper English, single player and singleplayer are less
correct.
(Contrary to multiplayer, which doesn't have a hyphen or space.)
Test Plan: Check for mistakes and omissions.
Reviewers: Gallaecio
Reviewed By: Gallaecio
Subscribers: Freagarach, elexis, O8 JS GUI
Differential Revision: https://code.wildfiregames.com/D2312
This was SVN commit r23176.
Decouples events from event handling, removes implicit-pause duplication
per messagebox and allows mods to modify message box values.
Differential Revision: https://code.wildfiregames.com/D2398
Comments By: Stan, Freagarach
This was SVN commit r23114.