|
game_launcher 1.1.0
Modern Linux game launcher with Steam / Proton / Wine integration
|
#include <game_list_proxy_model.h>
Public Types | |
| enum class | SortKey { Name , RecentlyPlayed , MostPlayed , Recent } |
Public Member Functions | |
| GameListProxyModel (QObject *parent=nullptr) | |
| void | clearAllFilters () |
| Reset all filters in one shot. | |
| void | setCollectionFilter (const QString &collection) |
| Restrict to a collection name, or empty for all. | |
| void | setRunnerFilter (const QString &runner) |
| Restrict to a specific runner version ("proton-ge-9", "Wine 9.0", etc.). | |
| void | setSearchText (const QString &text) |
| Free-text search (matches against name, developer, publisher). | |
| void | setShowFavoritesOnly (bool favoritesOnly) |
| void | setShowRunningOnly (bool running) |
| Additional booleans applied on top of the main filters. | |
| void | setShowUpdatesOnlyGame (bool updatesOnly) |
| void | setSortKey (SortKey key) |
| void | setSourceFilter (const QString &source) |
| Restrict to a specific source name ("Steam", "GOG", etc.) or empty for all. | |
| SortKey | sortKey () const |
Protected Member Functions | |
| bool | filterAcceptsRow (int sourceRow, const QModelIndex &sourceParent) const override |
| bool | lessThan (const QModelIndex &left, const QModelIndex &right) const override |
Definition at line 22 of file game_list_proxy_model.h.
|
strong |
| Enumerator | |
|---|---|
| Name | |
| RecentlyPlayed | |
| MostPlayed | |
| Recent | |
Definition at line 27 of file game_list_proxy_model.h.
|
explicit |
Definition at line 23 of file game_list_proxy_model.cpp.
| void GameListProxyModel::clearAllFilters | ( | ) |
Reset all filters in one shot.
Definition at line 96 of file game_list_proxy_model.cpp.
|
overrideprotected |
Definition at line 130 of file game_list_proxy_model.cpp.
References Game::collections, GameIsFavoriteRole, GameIsRunningRole, GameNeedsUpdateRole, GameRunnerRole, and GameSourceRole.
|
overrideprotected |
Definition at line 191 of file game_list_proxy_model.cpp.
References GameLastPlayedRole, GamePlayTimeRole, MostPlayed, Name, Recent, and RecentlyPlayed.
| void GameListProxyModel::setCollectionFilter | ( | const QString & | collection | ) |
Restrict to a collection name, or empty for all.
Definition at line 64 of file game_list_proxy_model.cpp.
| void GameListProxyModel::setRunnerFilter | ( | const QString & | runner | ) |
Restrict to a specific runner version ("proton-ge-9", "Wine 9.0", etc.).
Definition at line 56 of file game_list_proxy_model.cpp.
| void GameListProxyModel::setSearchText | ( | const QString & | text | ) |
Free-text search (matches against name, developer, publisher).
Empty string clears the filter.
Definition at line 40 of file game_list_proxy_model.cpp.
| void GameListProxyModel::setShowFavoritesOnly | ( | bool | favoritesOnly | ) |
Definition at line 88 of file game_list_proxy_model.cpp.
| void GameListProxyModel::setShowRunningOnly | ( | bool | running | ) |
Additional booleans applied on top of the main filters.
Definition at line 72 of file game_list_proxy_model.cpp.
| void GameListProxyModel::setShowUpdatesOnlyGame | ( | bool | updatesOnly | ) |
Definition at line 80 of file game_list_proxy_model.cpp.
| void GameListProxyModel::setSortKey | ( | SortKey | key | ) |
Definition at line 118 of file game_list_proxy_model.cpp.
| void GameListProxyModel::setSourceFilter | ( | const QString & | source | ) |
Restrict to a specific source name ("Steam", "GOG", etc.) or empty for all.
Definition at line 48 of file game_list_proxy_model.cpp.
|
inline |
Definition at line 67 of file game_list_proxy_model.h.