Cockatrice
2026-10-19-Development-3.1.2-beta.2
A virtual tabletop for multiplayer card games
Toggle main menu visibility
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
10
#include "
../../../interface/widgets/menus/tearoff_menu.h
"
11
#include "
abstract_player_component.h
"
12
13
#include <qtmetamacros.h>
14
15
class
PlayerGraphicsItem
;
16
class
QAction;
17
class
QMenu;
18
class
QWidget;
19
20
class
RfgMenu
:
public
TearOffMenu
,
public
AbstractPlayerComponent
21
{
22
Q_OBJECT
23
public
:
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
43
private
:
44
PlayerGraphicsItem
*
player
;
45
};
46
47
#endif
// COCKATRICE_RFG_MENU_H
abstract_player_component.h
Polymorphic interface for player-bound UI components managed by PlayerMenu.
AbstractPlayerComponent
Interface for player-bound UI components that need shortcut and translation lifecycle management.
Definition
abstract_player_component.h:18
PlayerGraphicsItem
Definition
player_graphics_item.h:39
RfgMenu::player
PlayerGraphicsItem * player
Definition
rfg_menu.h:44
RfgMenu::aMoveRfgToTopLibrary
QAction * aMoveRfgToTopLibrary
Definition
rfg_menu.h:38
RfgMenu::setShortcutsInactive
void setShortcutsInactive() override
Unbind keyboard shortcuts. Called when this player loses focus.
Definition
rfg_menu.h:31
RfgMenu::aViewRfg
QAction * aViewRfg
Definition
rfg_menu.h:37
RfgMenu::retranslateUi
void retranslateUi() override
Retranslate all user-visible strings. Called on language change.
Definition
rfg_menu.cpp:69
RfgMenu::setShortcutsActive
void setShortcutsActive() override
Bind keyboard shortcuts. Called when this player gains focus.
Definition
rfg_menu.h:28
RfgMenu::createMoveActions
void createMoveActions()
Definition
rfg_menu.cpp:40
RfgMenu::createViewActions
void createViewActions()
Definition
rfg_menu.cpp:61
RfgMenu::moveRfgMenu
QMenu * moveRfgMenu
Definition
rfg_menu.h:35
RfgMenu::aMoveRfgToHand
QAction * aMoveRfgToHand
Definition
rfg_menu.h:40
RfgMenu::RfgMenu
RfgMenu(PlayerGraphicsItem *player, QWidget *parent=nullptr)
Definition
rfg_menu.cpp:19
RfgMenu::aMoveRfgToGrave
QAction * aMoveRfgToGrave
Definition
rfg_menu.h:41
RfgMenu::aMoveRfgToBottomLibrary
QAction * aMoveRfgToBottomLibrary
Definition
rfg_menu.h:39
TearOffMenu::TearOffMenu
TearOffMenu(const QString &title, QWidget *parent=nullptr)
Definition
tearoff_menu.h:17
tearoff_menu.h
cockatrice
src
game_graphics
player
menu
rfg_menu.h
Generated by
1.18.0