Cockatrice 2025-11-30-Development-2.11.0-beta.38
A cross-platform virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
RemoteReplayList_TreeModel Class Reference

#include <remote_replay_list_tree_widget.h>

Inheritance diagram for RemoteReplayList_TreeModel:
[legend]
Collaboration diagram for RemoteReplayList_TreeModel:
[legend]

Classes

class  MatchNode
class  Node
class  ReplayNode

Signals

void treeRefreshed ()

Public Member Functions

 RemoteReplayList_TreeModel (AbstractClient *_client, QObject *parent=nullptr)
 ~RemoteReplayList_TreeModel () override
int rowCount (const QModelIndex &parent=QModelIndex()) const override
int columnCount (const QModelIndex &=QModelIndex()) const override
QVariant data (const QModelIndex &index, int role) const override
QVariant headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const override
QModelIndex index (int row, int column, const QModelIndex &parent=QModelIndex()) const override
QModelIndex parent (const QModelIndex &index) const override
Qt::ItemFlags flags (const QModelIndex &index) const override
void clearTree ()
void refreshTree ()
ServerInfo_Replay const * getReplay (const QModelIndex &index) const
ServerInfo_ReplayMatch const * getReplayMatch (const QModelIndex &index) const
ServerInfo_ReplayMatch const * getEnclosingReplayMatch (const QModelIndex &index) const
void addMatchInfo (const ServerInfo_ReplayMatch &matchInfo)
void updateMatchInfo (int gameId, const ServerInfo_ReplayMatch &matchInfo)
void removeMatchInfo (int gameId)

Private Slots

void replayListFinished (const Response &r)

Private Member Functions

void clearAll ()

Private Attributes

AbstractClientclient
QList< MatchNode * > replayMatches
QIcon dirIcon
QIcon fileIcon
QIcon lockIcon

Static Private Attributes

static const int numberOfColumns = 6

Constructor & Destructor Documentation

◆ RemoteReplayList_TreeModel()

RemoteReplayList_TreeModel::RemoteReplayList_TreeModel ( AbstractClient * _client,
QObject * parent = nullptr )
explicit
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ~RemoteReplayList_TreeModel()

RemoteReplayList_TreeModel::~RemoteReplayList_TreeModel ( )
override
Here is the call graph for this function:

Member Function Documentation

◆ addMatchInfo()

void RemoteReplayList_TreeModel::addMatchInfo ( const ServerInfo_ReplayMatch & matchInfo)
Here is the call graph for this function:

◆ clearAll()

void RemoteReplayList_TreeModel::clearAll ( )
private

Deletes all items in the model

Here is the caller graph for this function:

◆ clearTree()

void RemoteReplayList_TreeModel::clearTree ( )
Here is the call graph for this function:

◆ columnCount()

int RemoteReplayList_TreeModel::columnCount ( const QModelIndex & = QModelIndex()) const
inlinenodiscardoverride

◆ data()

QVariant RemoteReplayList_TreeModel::data ( const QModelIndex & index,
int role ) const
nodiscardoverride
Here is the call graph for this function:

◆ flags()

Qt::ItemFlags RemoteReplayList_TreeModel::flags ( const QModelIndex & index) const
nodiscardoverride
Here is the call graph for this function:

◆ getEnclosingReplayMatch()

ServerInfo_ReplayMatch const * RemoteReplayList_TreeModel::getEnclosingReplayMatch ( const QModelIndex & index) const
nodiscard
Here is the call graph for this function:

◆ getReplay()

ServerInfo_Replay const * RemoteReplayList_TreeModel::getReplay ( const QModelIndex & index) const
nodiscard
Here is the call graph for this function:

◆ getReplayMatch()

ServerInfo_ReplayMatch const * RemoteReplayList_TreeModel::getReplayMatch ( const QModelIndex & index) const
nodiscard
Here is the call graph for this function:

◆ headerData()

QVariant RemoteReplayList_TreeModel::headerData ( int section,
Qt::Orientation orientation,
int role = Qt::DisplayRole ) const
nodiscardoverride

◆ index()

QModelIndex RemoteReplayList_TreeModel::index ( int row,
int column,
const QModelIndex & parent = QModelIndex() ) const
nodiscardoverride
Here is the call graph for this function:
Here is the caller graph for this function:

◆ parent()

QModelIndex RemoteReplayList_TreeModel::parent ( const QModelIndex & index) const
nodiscardoverride
Here is the caller graph for this function:

◆ refreshTree()

void RemoteReplayList_TreeModel::refreshTree ( )
Here is the call graph for this function:

◆ removeMatchInfo()

void RemoteReplayList_TreeModel::removeMatchInfo ( int gameId)

◆ replayListFinished

void RemoteReplayList_TreeModel::replayListFinished ( const Response & r)
privateslot
Here is the call graph for this function:
Here is the caller graph for this function:

◆ rowCount()

int RemoteReplayList_TreeModel::rowCount ( const QModelIndex & parent = QModelIndex()) const
nodiscardoverride
Here is the call graph for this function:

◆ treeRefreshed

void RemoteReplayList_TreeModel::treeRefreshed ( )
signal
Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateMatchInfo()

void RemoteReplayList_TreeModel::updateMatchInfo ( int gameId,
const ServerInfo_ReplayMatch & matchInfo )

Member Data Documentation

◆ client

AbstractClient* RemoteReplayList_TreeModel::client
private

◆ dirIcon

QIcon RemoteReplayList_TreeModel::dirIcon
private

◆ fileIcon

QIcon RemoteReplayList_TreeModel::fileIcon
private

◆ lockIcon

QIcon RemoteReplayList_TreeModel::lockIcon
private

◆ numberOfColumns

const int RemoteReplayList_TreeModel::numberOfColumns = 6
staticprivate

◆ replayMatches

QList<MatchNode *> RemoteReplayList_TreeModel::replayMatches
private

The documentation for this class was generated from the following files: