summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinQt/NetPlay/GameListDialog.h
blob: f85d96a4e59e7884c0d8153a3e3c878ce5d31d2a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
// Copyright 2017 Dolphin Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later

#pragma once

#include <QDialog>

#include "DolphinQt/GameList/GameListModel.h"

class QVBoxLayout;
class QListWidget;
class QDialogButtonBox;

namespace UICommon
{
class GameFile;
}

class GameListDialog : public QDialog
{
  Q_OBJECT
public:
  explicit GameListDialog(const GameListModel& game_list_model, QWidget* parent);

  int exec() override;
  const UICommon::GameFile& GetSelectedGame() const;

private:
  void CreateWidgets();
  void ConnectWidgets();
  void PopulateGameList();

  const GameListModel& m_game_list_model;
  QVBoxLayout* m_main_layout;
  QListWidget* m_game_list;
  QDialogButtonBox* m_button_box;
};