diff --git a/pcsx2-qt/GameList/GameListWidget.cpp b/pcsx2-qt/GameList/GameListWidget.cpp index c447dee16c..81a465f1a2 100644 --- a/pcsx2-qt/GameList/GameListWidget.cpp +++ b/pcsx2-qt/GameList/GameListWidget.cpp @@ -241,6 +241,8 @@ void GameListWidget::initialize() else m_ui.stack->setCurrentIndex(0); + setFocusProxy(m_ui.stack->currentWidget()); + updateToolbar(); resizeTableViewColumnsToFit(); } @@ -294,7 +296,10 @@ void GameListWidget::onRefreshProgress(const QString& status, int current, int t { // switch away from the placeholder while we scan, in case we find anything if (m_ui.stack->currentIndex() == 2) + { m_ui.stack->setCurrentIndex(Host::GetBaseBoolSettingValue("UI", "GameListGridView", false) ? 1 : 0); + setFocusProxy(m_ui.stack->currentWidget()); + } m_model->refresh(); emit refreshProgress(status, current, total); @@ -312,7 +317,10 @@ void GameListWidget::onRefreshComplete() // if we still had no games, switch to the helper widget if (m_model->rowCount() == 0) + { m_ui.stack->setCurrentIndex(2); + setFocusProxy(nullptr); + } } void GameListWidget::onSelectionModelCurrentChanged(const QModelIndex& current, const QModelIndex& previous) @@ -436,6 +444,7 @@ void GameListWidget::showGameList() Host::SetBaseBoolSettingValue("UI", "GameListGridView", false); Host::CommitBaseSettingChanges(); m_ui.stack->setCurrentIndex(0); + setFocusProxy(m_ui.stack->currentWidget()); resizeTableViewColumnsToFit(); updateToolbar(); emit layoutChange(); @@ -453,6 +462,7 @@ void GameListWidget::showGameGrid() Host::SetBaseBoolSettingValue("UI", "GameListGridView", true); Host::CommitBaseSettingChanges(); m_ui.stack->setCurrentIndex(1); + setFocusProxy(m_ui.stack->currentWidget()); updateToolbar(); emit layoutChange(); }