mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2025-01-18 06:25:37 +00:00
Qt: Set focus to display window when starting
This commit is contained in:
parent
40e1b7af23
commit
d61f12cb4e
|
@ -108,8 +108,8 @@ void MainWindow::setupAdditionalUi()
|
||||||
m_game_list_widget->initialize(m_host_interface);
|
m_game_list_widget->initialize(m_host_interface);
|
||||||
m_ui.mainContainer->insertWidget(0, m_game_list_widget);
|
m_ui.mainContainer->insertWidget(0, m_game_list_widget);
|
||||||
|
|
||||||
QWidget* display_widget = m_host_interface->createDisplayWidget(m_ui.mainContainer);
|
m_display_widget = m_host_interface->createDisplayWidget(m_ui.mainContainer);
|
||||||
m_ui.mainContainer->insertWidget(1, display_widget);
|
m_ui.mainContainer->insertWidget(1, m_display_widget);
|
||||||
|
|
||||||
m_ui.mainContainer->setCurrentIndex(0);
|
m_ui.mainContainer->setCurrentIndex(0);
|
||||||
}
|
}
|
||||||
|
@ -140,6 +140,7 @@ void MainWindow::switchToGameListView()
|
||||||
void MainWindow::switchToEmulationView()
|
void MainWindow::switchToEmulationView()
|
||||||
{
|
{
|
||||||
m_ui.mainContainer->setCurrentIndex(1);
|
m_ui.mainContainer->setCurrentIndex(1);
|
||||||
|
m_display_widget->setFocus();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::connectSignals()
|
void MainWindow::connectSignals()
|
||||||
|
|
|
@ -50,6 +50,7 @@ private:
|
||||||
|
|
||||||
std::unique_ptr<GameList> m_game_list;
|
std::unique_ptr<GameList> m_game_list;
|
||||||
GameListWidget* m_game_list_widget = nullptr;
|
GameListWidget* m_game_list_widget = nullptr;
|
||||||
|
QWidget* m_display_widget = nullptr;
|
||||||
|
|
||||||
SettingsDialog* m_settings_dialog = nullptr;
|
SettingsDialog* m_settings_dialog = nullptr;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue