Merge pull request #6839 from spycrab/qt_start_top
Qt: Fix render widget not being on top when using -n / -e
This commit is contained in:
commit
9d1157f695
|
@ -180,7 +180,7 @@ int main(int argc, char* argv[])
|
||||||
MainWindow win{std::move(boot)};
|
MainWindow win{std::move(boot)};
|
||||||
if (options.is_set("debugger"))
|
if (options.is_set("debugger"))
|
||||||
Settings::Instance().SetDebugModeEnabled(true);
|
Settings::Instance().SetDebugModeEnabled(true);
|
||||||
win.show();
|
win.Show();
|
||||||
|
|
||||||
#if defined(USE_ANALYTICS) && USE_ANALYTICS
|
#if defined(USE_ANALYTICS) && USE_ANALYTICS
|
||||||
if (!SConfig::GetInstance().m_analytics_permission_asked)
|
if (!SConfig::GetInstance().m_analytics_permission_asked)
|
||||||
|
|
|
@ -110,7 +110,7 @@ MainWindow::MainWindow(std::unique_ptr<BootParameters> boot_parameters) : QMainW
|
||||||
NetPlayInit();
|
NetPlayInit();
|
||||||
|
|
||||||
if (boot_parameters)
|
if (boot_parameters)
|
||||||
StartGame(std::move(boot_parameters));
|
m_pending_boot = std::move(boot_parameters);
|
||||||
|
|
||||||
QSettings& settings = Settings::GetQSettings();
|
QSettings& settings = Settings::GetQSettings();
|
||||||
|
|
||||||
|
@ -1351,3 +1351,15 @@ void MainWindow::OnUpdateProgressDialog(QString title, int progress, int total)
|
||||||
m_progress_dialog = nullptr;
|
m_progress_dialog = nullptr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MainWindow::Show()
|
||||||
|
{
|
||||||
|
QWidget::show();
|
||||||
|
|
||||||
|
// If the booting of a game was requested on start up, do that now
|
||||||
|
if (m_pending_boot != nullptr)
|
||||||
|
{
|
||||||
|
StartGame(std::move(m_pending_boot));
|
||||||
|
m_pending_boot.reset();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -58,6 +58,8 @@ public:
|
||||||
explicit MainWindow(std::unique_ptr<BootParameters> boot_parameters);
|
explicit MainWindow(std::unique_ptr<BootParameters> boot_parameters);
|
||||||
~MainWindow();
|
~MainWindow();
|
||||||
|
|
||||||
|
void Show();
|
||||||
|
|
||||||
bool eventFilter(QObject* object, QEvent* event) override;
|
bool eventFilter(QObject* object, QEvent* event) override;
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
|
|
Loading…
Reference in New Issue