Add fade out effect to the loading screen

This commit is contained in:
James Rowe
2019-01-21 09:20:16 -07:00
parent 3740adb6f5
commit 3ca0af8bb3
4 changed files with 158 additions and 94 deletions

View File

@ -415,6 +415,13 @@ void GMainWindow::InitializeWidgets() {
loading_screen = new LoadingScreen(this);
loading_screen->hide();
ui.horizontalLayout->addWidget(loading_screen);
connect(loading_screen, &LoadingScreen::Hidden, [&] {
loading_screen->Clear();
if (emulation_running) {
render_window->show();
render_window->setFocus();
}
});
// Create status bar
message_label = new QLabel();
@ -1513,10 +1520,7 @@ void GMainWindow::OnStopGame() {
}
void GMainWindow::OnLoadComplete() {
loading_screen->hide();
loading_screen->Clear();
render_window->show();
render_window->setFocus();
loading_screen->OnLoadComplete();
}
void GMainWindow::OnMenuReportCompatibility() {