mirror of
git://projects.qi-hardware.com/gmenu2x.git
synced 2025-04-21 12:27:27 +03:00
Fixed bug with launch screen and double buffering
LinkApp::drawRun() assumes the layers below are already painted when it is called, but this was not the case. With single buffering, the previous frame was still there so it still looked good, but with double buffering the buffer typically contains an outdated screen. Long term I think the launch should happen at the outermost scope, so all destructors get a chance to run. This commit is a small step in that direction, by exiting the main loop before launching.
This commit is contained in:
@@ -372,7 +372,7 @@ void LinkApp::start() {
|
||||
if (!selectordir.empty())
|
||||
selector();
|
||||
else
|
||||
launch();
|
||||
gmenu2x->queueLaunch(this, "");
|
||||
}
|
||||
|
||||
void LinkApp::showManual() {
|
||||
@@ -547,13 +547,11 @@ void LinkApp::selector(int startSelection, const string &selectorDir) {
|
||||
selectordir = selectedDir;
|
||||
}
|
||||
gmenu2x->writeTmp(selection, selectedDir);
|
||||
launch(selectedDir + sel.getFile());
|
||||
gmenu2x->queueLaunch(this, selectedDir + sel.getFile());
|
||||
}
|
||||
}
|
||||
|
||||
void LinkApp::launch(const string &selectedFile) {
|
||||
drawRun();
|
||||
|
||||
save();
|
||||
|
||||
if (isOpk()) {
|
||||
|
||||
Reference in New Issue
Block a user