Cockatrice 2026-10-19-Development-3.1.2-beta.2
A virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
rfg_menu.h
Go to the documentation of this file.
1
6
7#ifndef COCKATRICE_RFG_MENU_H
8#define COCKATRICE_RFG_MENU_H
9
12
13#include <qtmetamacros.h>
14
16class QAction;
17class QMenu;
18class QWidget;
19
21{
22 Q_OBJECT
23public:
24 explicit RfgMenu(PlayerGraphicsItem *player, QWidget *parent = nullptr);
25 void createMoveActions();
26 void createViewActions();
27 void retranslateUi() override;
28 void setShortcutsActive() override
29 {
30 }
31 void setShortcutsInactive() override
32 {
33 }
34
35 QMenu *moveRfgMenu = nullptr;
36
37 QAction *aViewRfg = nullptr;
38 QAction *aMoveRfgToTopLibrary = nullptr;
39 QAction *aMoveRfgToBottomLibrary = nullptr;
40 QAction *aMoveRfgToHand = nullptr;
41 QAction *aMoveRfgToGrave = nullptr;
42
43private:
45};
46
47#endif // COCKATRICE_RFG_MENU_H
Polymorphic interface for player-bound UI components managed by PlayerMenu.
Interface for player-bound UI components that need shortcut and translation lifecycle management.
Definition abstract_player_component.h:18
Definition player_graphics_item.h:39
PlayerGraphicsItem * player
Definition rfg_menu.h:44
QAction * aMoveRfgToTopLibrary
Definition rfg_menu.h:38
void setShortcutsInactive() override
Unbind keyboard shortcuts. Called when this player loses focus.
Definition rfg_menu.h:31
QAction * aViewRfg
Definition rfg_menu.h:37
void retranslateUi() override
Retranslate all user-visible strings. Called on language change.
Definition rfg_menu.cpp:69
void setShortcutsActive() override
Bind keyboard shortcuts. Called when this player gains focus.
Definition rfg_menu.h:28
void createMoveActions()
Definition rfg_menu.cpp:40
void createViewActions()
Definition rfg_menu.cpp:61
QMenu * moveRfgMenu
Definition rfg_menu.h:35
QAction * aMoveRfgToHand
Definition rfg_menu.h:40
RfgMenu(PlayerGraphicsItem *player, QWidget *parent=nullptr)
Definition rfg_menu.cpp:19
QAction * aMoveRfgToGrave
Definition rfg_menu.h:41
QAction * aMoveRfgToBottomLibrary
Definition rfg_menu.h:39
TearOffMenu(const QString &title, QWidget *parent=nullptr)
Definition tearoff_menu.h:17