mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-02 03:23:56 -07:00
Add game filtering for spectator attributes (#4127)
This commit is contained in:
parent
1a94261490
commit
a49c4865bb
8 changed files with 291 additions and 62 deletions
|
|
@ -80,12 +80,15 @@ private:
|
|||
// - filterAcceptsRow()
|
||||
bool showBuddiesOnlyGames;
|
||||
bool hideIgnoredUserGames;
|
||||
bool unavailableGamesVisible;
|
||||
bool showFullGames;
|
||||
bool showGamesThatStarted;
|
||||
bool showPasswordProtectedGames;
|
||||
QString gameNameFilter, creatorNameFilter;
|
||||
QSet<int> gameTypeFilter;
|
||||
quint32 maxPlayersFilterMin, maxPlayersFilterMax;
|
||||
QTime maxGameAge;
|
||||
bool showOnlyIfSpectatorsCanWatch, showSpectatorPasswordProtected, showOnlyIfSpectatorsCanChat,
|
||||
showOnlyIfSpectatorsCanSeeHands;
|
||||
|
||||
public:
|
||||
GamesProxyModel(QObject *parent = nullptr, const TabSupervisor *_tabSupervisor = nullptr);
|
||||
|
|
@ -100,11 +103,16 @@ public:
|
|||
return hideIgnoredUserGames;
|
||||
}
|
||||
void setHideIgnoredUserGames(bool _hideIgnoredUserGames);
|
||||
bool getUnavailableGamesVisible() const
|
||||
bool getShowFullGames() const
|
||||
{
|
||||
return unavailableGamesVisible;
|
||||
return showFullGames;
|
||||
}
|
||||
void setUnavailableGamesVisible(bool _unavailableGamesVisible);
|
||||
void setShowFullGames(bool _showFullGames);
|
||||
bool getShowGamesThatStarted() const
|
||||
{
|
||||
return showGamesThatStarted;
|
||||
}
|
||||
void setShowGamesThatStarted(bool _showGamesThatStarted);
|
||||
bool getShowPasswordProtectedGames() const
|
||||
{
|
||||
return showPasswordProtectedGames;
|
||||
|
|
@ -139,6 +147,26 @@ public:
|
|||
return maxGameAge;
|
||||
}
|
||||
void setMaxGameAge(const QTime &_maxGameAge);
|
||||
bool getShowOnlyIfSpectatorsCanWatch() const
|
||||
{
|
||||
return showOnlyIfSpectatorsCanWatch;
|
||||
}
|
||||
void setShowOnlyIfSpectatorsCanWatch(bool _showOnlyIfSpectatorsCanWatch);
|
||||
bool getShowSpectatorPasswordProtected() const
|
||||
{
|
||||
return showSpectatorPasswordProtected;
|
||||
}
|
||||
void setShowSpectatorPasswordProtected(bool _showSpectatorPasswordProtected);
|
||||
bool getShowOnlyIfSpectatorsCanChat() const
|
||||
{
|
||||
return showOnlyIfSpectatorsCanChat;
|
||||
}
|
||||
void setShowOnlyIfSpectatorsCanChat(bool _showOnlyIfSpectatorsCanChat);
|
||||
bool getShowOnlyIfSpectatorsCanSeeHands() const
|
||||
{
|
||||
return showOnlyIfSpectatorsCanSeeHands;
|
||||
}
|
||||
void setShowOnlyIfSpectatorsCanSeeHands(bool _showOnlyIfSpectatorsCanSeeHands);
|
||||
|
||||
int getNumFilteredGames() const;
|
||||
void resetFilterParameters();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue