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

#include <card_menu.h>

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

Public Member Functions

 CardMenu (Player *player, const CardItem *card, bool shortcutsActive)
void removePlayer (Player *playerToRemove)
void createTableMenu ()
void createStackMenu ()
void createGraveyardOrExileMenu ()
void createHandOrCustomZoneMenu ()

Public Attributes

QMenu * mCardCounters
QAction * aPlay
QAction * aPlayFacedown
QAction * aRevealToAll
QAction * aHide
QAction * aClone
QAction * aSelectAll
QAction * aSelectRow
QAction * aSelectColumn
QAction * aDrawArrow
QAction * aTap
QAction * aDoesntUntap
QAction * aFlip
QAction * aPeek
QAction * aAttach
QAction * aUnattach
QAction * aSetAnnotation
QList< QAction * > aAddCounter
QList< QAction * > aSetCounter
QList< QAction * > aRemoveCounter

Private Member Functions

void addRelatedCardActions ()
void retranslateUi ()
void initContextualPlayersMenu (QMenu *menu, QAction *allPlayersAction)
 Populates the menu with an action for each active player.
void setShortcutsActive ()
void addRelatedCardView ()

Private Attributes

Playerplayer
const CardItemcard
QList< QPair< QString, int > > playersInfo
bool shortcutsActive

Constructor & Destructor Documentation

◆ CardMenu()

CardMenu::CardMenu ( Player * player,
const CardItem * card,
bool shortcutsActive )
explicit
Here is the call graph for this function:

Member Function Documentation

◆ addRelatedCardActions()

void CardMenu::addRelatedCardActions ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ addRelatedCardView()

void CardMenu::addRelatedCardView ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ createGraveyardOrExileMenu()

void CardMenu::createGraveyardOrExileMenu ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ createHandOrCustomZoneMenu()

void CardMenu::createHandOrCustomZoneMenu ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ createStackMenu()

void CardMenu::createStackMenu ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ createTableMenu()

void CardMenu::createTableMenu ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ initContextualPlayersMenu()

void CardMenu::initContextualPlayersMenu ( QMenu * menu,
QAction * allPlayersAction )
private

Populates the menu with an action for each active player.

The "all players" action is created separately, so it has to be passed into this function. It will be put at the top of the menu.

Parameters
menuThe menu to add the player actions to.
allPlayersActionThe action for "all players".
Here is the caller graph for this function:

◆ removePlayer()

void CardMenu::removePlayer ( Player * playerToRemove)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ retranslateUi()

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

◆ setShortcutsActive()

void CardMenu::setShortcutsActive ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ aAddCounter

QList<QAction *> CardMenu::aAddCounter

◆ aAttach

QAction* CardMenu::aAttach

◆ aClone

QAction* CardMenu::aClone

◆ aDoesntUntap

QAction * CardMenu::aDoesntUntap

◆ aDrawArrow

QAction* CardMenu::aDrawArrow

◆ aFlip

QAction* CardMenu::aFlip

◆ aHide

QAction* CardMenu::aHide

◆ aPeek

QAction * CardMenu::aPeek

◆ aPlay

QAction* CardMenu::aPlay

◆ aPlayFacedown

QAction * CardMenu::aPlayFacedown

◆ aRemoveCounter

QList<QAction *> CardMenu::aRemoveCounter

◆ aRevealToAll

QAction* CardMenu::aRevealToAll

◆ aSelectAll

QAction* CardMenu::aSelectAll

◆ aSelectColumn

QAction * CardMenu::aSelectColumn

◆ aSelectRow

QAction * CardMenu::aSelectRow

◆ aSetAnnotation

QAction* CardMenu::aSetAnnotation

◆ aSetCounter

QList<QAction *> CardMenu::aSetCounter

◆ aTap

QAction* CardMenu::aTap

◆ aUnattach

QAction * CardMenu::aUnattach

◆ card

const CardItem* CardMenu::card
private

◆ mCardCounters

QMenu* CardMenu::mCardCounters

◆ player

Player* CardMenu::player
private

◆ playersInfo

QList<QPair<QString, int> > CardMenu::playersInfo
private

◆ shortcutsActive

bool CardMenu::shortcutsActive
private

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