Add initial work on Qt frontend

This commit is contained in:
Connor McLaughlin
2019-12-31 16:17:17 +10:00
parent 98214a9327
commit f3e9c3ec8c
64 changed files with 3490 additions and 14 deletions

View File

@@ -0,0 +1,36 @@
#pragma once
#include "core/game_list.h"
#include <QtWidgets/QStackedWidget>
#include <QtWidgets/QTableView>
class GameListModel;
class QtHostInterface;
class GameListWidget : public QStackedWidget
{
Q_OBJECT
public:
GameListWidget(QWidget* parent = nullptr);
~GameListWidget();
void initialize(QtHostInterface* host_interface);
Q_SIGNALS:
void bootEntryRequested(const GameList::GameListEntry& entry);
private Q_SLOTS:
void onGameListRefreshed();
void onTableViewItemDoubleClicked(const QModelIndex& index);
protected:
void resizeEvent(QResizeEvent* event);
private:
QtHostInterface* m_host_interface = nullptr;
GameList* m_game_list = nullptr;
GameListModel* m_table_model = nullptr;
QTableView* m_table_view = nullptr;
};