mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-02 15:16:46 +00:00
GUI: Add exitLoop() method to GuiManager
The idea is to allow backends to start a game even after the LauncherDialog has been created, and for that they need a way to close the existing GUI dialogs.
This commit is contained in:
parent
5e888a601e
commit
32bbf489e9
@ -449,6 +449,11 @@ void GuiManager::runLoop() {
|
||||
#endif
|
||||
}
|
||||
|
||||
void GuiManager::exitLoop() {
|
||||
while (!_dialogStack.empty())
|
||||
getTopDialog()->close();
|
||||
}
|
||||
|
||||
#pragma mark -
|
||||
|
||||
void GuiManager::saveState() {
|
||||
|
@ -75,6 +75,11 @@ public:
|
||||
// until no dialogs are active anymore.
|
||||
void runLoop();
|
||||
|
||||
// If the GUI loop is running close all the dialogs causing the loop to finish.
|
||||
// Typically you may want to use it after setting the ConfMan active domain to
|
||||
// a game domain to cause the game to start.
|
||||
void exitLoop();
|
||||
|
||||
void processEvent(const Common::Event &event, Dialog *const activeDialog);
|
||||
Common::Keymap *getKeymap() const;
|
||||
void scheduleTopDialogRedraw();
|
||||
|
Loading…
Reference in New Issue
Block a user