Cockatrice 2026-10-19-Development-3.1.2-beta.2
A virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
VisualDeckStorageWidget Class Referencefinal

#include <visual_deck_storage_widget.h>

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

Public Slots

void createRootFolderWidget ()
 Starts scanning the deck folder and rebuilds the folder tree and previews.
void updateShowFolders (bool enabled)
void updateTagsVisibility (bool visible)
void updateSelectionAnimationEnabled (bool enabled)
void updateSortOrder ()
void updateTagFilter ()
void updateColorFilter ()
void updateSearchFilter (const QString &text)

Signals

void deckLoadRequested (const QString &filePath)
void openDeckEditor (const LoadedDeck &deck)
void shareDeckRequested (const QString &filePath)
void shareSelectionChanged ()
void shareRequested ()

Public Member Functions

 VisualDeckStorageWidget (QWidget *parent)
void refreshIfPossible ()
void retranslateUi ()
void setShareSelectable (bool selectable)
bool isShareSelectable () const
QStringList selectedFilePaths () const
void setShareSelectedFiles (const QStringList &paths)
void clearShareSelection ()
void setShareAvailable (bool available)
const VisualDeckStorageQuickSettingsWidget * settings () const
VisualDeckStorageModel * model () const
VisualDeckStorageSortFilterProxyModel * proxyModel () const

Public Attributes

VisualDeckStorageTagFilterWidget * tagFilterWidget
bool deckPreviewSelectionAnimationEnabled

Protected Member Functions

void resizeEvent (QResizeEvent *event) override
void showEvent (QShowEvent *event) override

Private Member Functions

void reapplySortAndFilters ()
QSet< QString > gatherVisibleTags () const
 The tags of all decks currently accepted by the proxy model.

Private Attributes

QVBoxLayout * layout
QWidget * searchAndSortContainer
QHBoxLayout * searchAndSortLayout
QLabel * databaseLoadIndicator
VisualDeckStorageSortWidget * sortWidget
VisualDeckStorageSearchWidget * searchWidget
DeckPreviewColorIdentityFilterWidget * deckPreviewColorIdentityFilterWidget
QToolButton * refreshButton
QToolButton * shareButton
VisualDeckStorageQuickSettingsWidget * quickSettingsWidget
QScrollArea * scrollArea
VisualDeckStorageFolderDisplayWidget * folderWidget = nullptr
VisualDeckStorageModel * storageModel = nullptr
VisualDeckStorageSortFilterProxyModel * storageProxyModel = nullptr
QTimer * refreshTimer = nullptr
 Coalesces the re-apply/refresh burst following a batch of deck loads.
bool shareSelectable = false

Constructor & Destructor Documentation

◆ VisualDeckStorageWidget()

VisualDeckStorageWidget::VisualDeckStorageWidget ( QWidget * parent)
explicit
Here is the call graph for this function:
Here is the caller graph for this function:

Member Function Documentation

◆ clearShareSelection()

void VisualDeckStorageWidget::clearShareSelection ( )
Here is the caller graph for this function:

◆ createRootFolderWidget

void VisualDeckStorageWidget::createRootFolderWidget ( )
slot

Starts scanning the deck folder and rebuilds the folder tree and previews.

Scans the deck folder and rebuilds the folder tree of deck previews.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ deckLoadRequested

void VisualDeckStorageWidget::deckLoadRequested ( const QString & filePath)
signal
Here is the caller graph for this function:

◆ gatherVisibleTags()

QSet< QString > VisualDeckStorageWidget::gatherVisibleTags ( ) const
nodiscardprivate

The tags of all decks currently accepted by the proxy model.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ isShareSelectable()

bool VisualDeckStorageWidget::isShareSelectable ( ) const
nodiscard
Here is the caller graph for this function:

◆ model()

VisualDeckStorageModel * VisualDeckStorageWidget::model ( ) const
inlinenodiscard
Here is the caller graph for this function:

◆ openDeckEditor

void VisualDeckStorageWidget::openDeckEditor ( const LoadedDeck & deck)
signal
Here is the caller graph for this function:

◆ proxyModel()

VisualDeckStorageSortFilterProxyModel * VisualDeckStorageWidget::proxyModel ( ) const
inlinenodiscard
Here is the caller graph for this function:

◆ reapplySortAndFilters()

void VisualDeckStorageWidget::reapplySortAndFilters ( )
private

Reapplies all sort and filter options by updating the proxy model.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ refreshIfPossible()

void VisualDeckStorageWidget::refreshIfPossible ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ resizeEvent()

void VisualDeckStorageWidget::resizeEvent ( QResizeEvent * event)
overrideprotected
Here is the caller graph for this function:

◆ retranslateUi()

void VisualDeckStorageWidget::retranslateUi ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ selectedFilePaths()

QStringList VisualDeckStorageWidget::selectedFilePaths ( ) const
nodiscard
Here is the caller graph for this function:

◆ setShareAvailable()

void VisualDeckStorageWidget::setShareAvailable ( bool available)
Here is the caller graph for this function:

◆ setShareSelectable()

void VisualDeckStorageWidget::setShareSelectable ( bool selectable)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ setShareSelectedFiles()

void VisualDeckStorageWidget::setShareSelectedFiles ( const QStringList & paths)
Here is the caller graph for this function:

◆ settings()

const VisualDeckStorageQuickSettingsWidget * VisualDeckStorageWidget::settings ( ) const
nodiscard

Gets a const pointer to the quick settings so that the values can be accessed.

Here is the caller graph for this function:

◆ shareDeckRequested

void VisualDeckStorageWidget::shareDeckRequested ( const QString & filePath)
signal
Here is the caller graph for this function:

◆ shareRequested

void VisualDeckStorageWidget::shareRequested ( )
signal
Here is the call graph for this function:
Here is the caller graph for this function:

◆ shareSelectionChanged

void VisualDeckStorageWidget::shareSelectionChanged ( )
signal
Here is the caller graph for this function:

◆ showEvent()

void VisualDeckStorageWidget::showEvent ( QShowEvent * event)
overrideprotected
Here is the caller graph for this function:

◆ updateColorFilter

void VisualDeckStorageWidget::updateColorFilter ( )
slot

Pushes the color identity filter widget's state into the proxy model.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateSearchFilter

void VisualDeckStorageWidget::updateSearchFilter ( const QString & text)
slot

Pushes the search bar's text into the proxy model.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateSelectionAnimationEnabled

void VisualDeckStorageWidget::updateSelectionAnimationEnabled ( bool enabled)
slot
Here is the caller graph for this function:

◆ updateShowFolders

void VisualDeckStorageWidget::updateShowFolders ( bool enabled)
slot
Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateSortOrder

void VisualDeckStorageWidget::updateSortOrder ( )
slot
Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateTagFilter

void VisualDeckStorageWidget::updateTagFilter ( )
slot
Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateTagsVisibility

void VisualDeckStorageWidget::updateTagsVisibility ( bool visible)
slot
Here is the caller graph for this function:

Member Data Documentation

◆ databaseLoadIndicator

QLabel* VisualDeckStorageWidget::databaseLoadIndicator
private

◆ deckPreviewColorIdentityFilterWidget

DeckPreviewColorIdentityFilterWidget* VisualDeckStorageWidget::deckPreviewColorIdentityFilterWidget
private

◆ deckPreviewSelectionAnimationEnabled

bool VisualDeckStorageWidget::deckPreviewSelectionAnimationEnabled

◆ folderWidget

VisualDeckStorageFolderDisplayWidget* VisualDeckStorageWidget::folderWidget = nullptr
private

◆ layout

QVBoxLayout* VisualDeckStorageWidget::layout
private

◆ quickSettingsWidget

VisualDeckStorageQuickSettingsWidget* VisualDeckStorageWidget::quickSettingsWidget
private

◆ refreshButton

QToolButton* VisualDeckStorageWidget::refreshButton
private

◆ refreshTimer

QTimer* VisualDeckStorageWidget::refreshTimer = nullptr
private

Coalesces the re-apply/refresh burst following a batch of deck loads.

◆ scrollArea

QScrollArea* VisualDeckStorageWidget::scrollArea
private

◆ searchAndSortContainer

QWidget* VisualDeckStorageWidget::searchAndSortContainer
private

◆ searchAndSortLayout

QHBoxLayout* VisualDeckStorageWidget::searchAndSortLayout
private

◆ searchWidget

VisualDeckStorageSearchWidget* VisualDeckStorageWidget::searchWidget
private

◆ shareButton

QToolButton* VisualDeckStorageWidget::shareButton
private

◆ shareSelectable

bool VisualDeckStorageWidget::shareSelectable = false
private

◆ sortWidget

VisualDeckStorageSortWidget* VisualDeckStorageWidget::sortWidget
private

◆ storageModel

VisualDeckStorageModel* VisualDeckStorageWidget::storageModel = nullptr
private

◆ storageProxyModel

VisualDeckStorageSortFilterProxyModel* VisualDeckStorageWidget::storageProxyModel = nullptr
private

◆ tagFilterWidget

VisualDeckStorageTagFilterWidget* VisualDeckStorageWidget::tagFilterWidget

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