Skip to content
Permalink
Browse files

Merge pull request #8034 from spycrab/qt_npb_rclick

Qt/NetPlayBrowser: Connect to session on double-click
  • Loading branch information...
spycrab committed Apr 24, 2019
2 parents 127b4e7 + e97c61c commit ac879b2475b68b1435ccff8ace71aefaad486388
Showing with 5 additions and 0 deletions.
  1. +5 −0 Source/Core/DolphinQt/NetPlay/NetPlayBrowser.cpp
@@ -136,8 +136,10 @@ void NetPlayBrowser::ConnectWidgets()

connect(m_edit_name, &QLineEdit::textChanged, this, &NetPlayBrowser::Refresh);
connect(m_edit_game_id, &QLineEdit::textChanged, this, &NetPlayBrowser::Refresh);

connect(m_table_widget, &QTableWidget::itemSelectionChanged, this,
&NetPlayBrowser::OnSelectionChanged);
connect(m_table_widget, &QTableWidget::itemDoubleClicked, this, &NetPlayBrowser::accept);
}

void NetPlayBrowser::Refresh()
@@ -266,6 +268,9 @@ void NetPlayBrowser::OnSelectionChanged()

void NetPlayBrowser::accept()
{
if (m_table_widget->selectedItems().isEmpty())
return;

const int index = m_table_widget->selectedItems()[0]->row();

NetPlaySession& session = m_sessions[index];

0 comments on commit ac879b2

Please sign in to comment.
You can’t perform that action at this time.