#include <kstdgameaction.h>
Public Types | |
| enum | StdGameAction { New = 1, Load, LoadRecent, Save, SaveAs, End, Pause, Highscores, Print, Quit, Repeat, Undo, Redo, Roll, EndTurn, Carddecks, ChooseGameType, ConfigureHighscores, Restart, Hint, Demo, Solve, ActionNone } |
| The standard menubar and toolbar actions. More... | |
Public Member Functions | |
| KStdGameAction () | |
| ~KStdGameAction () | |
Static Public Member Functions | |
| static KAction * | create (StdGameAction id, const char *name, const QObject *recvr, const char *slot, KActionCollection *parent) |
| Creates an action corresponding to the KStdAction::StdAction enum. | |
| static KAction * | create (StdGameAction id, const QObject *recvr, const char *slot, KActionCollection *parent) |
| static KAction * | action (StdGameAction act_enum, const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Retrieve the action corresponding to the KStdGameAction::StdGameAction enum. | |
| static const char * | name (StdGameAction id) |
| This will return the internal name of a given standard action. | |
| static const char * | stdName (StdGameAction act_enum) |
| This will return the internal name of a given standard action. | |
| static KAction * | gameNew (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Start a new game. | |
| static KAction * | load (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Load a previousely saved game. | |
| static KRecentFilesAction * | loadRecent (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Load a recently loaded game. | |
| static KAction * | save (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Save the current game. | |
| static KAction * | saveAs (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Save the current game under a different filename. | |
| static KToggleAction * | pause (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Pause the game. | |
| static KAction * | highscores (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Show the highscores. | |
| static KAction * | end (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| End the current game, but do not quit the program. | |
| static KAction * | print (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Print the current screen? Game? Whatever - hardly used in games but there is at least one example (ktuberling). | |
| static KAction * | quit (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Quit the game. | |
| static KAction * | repeat (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Repeat the last move. | |
| static KAction * | undo (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Undo the last move. | |
| static KAction * | redo (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Redo the last move (which has been undone). | |
| static KAction * | roll (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Roll die or dice. | |
| static KAction * | endTurn (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| End the current turn (not the game). | |
| static KAction * | carddecks (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Display configure carddecks dialog. | |
| static KAction * | configureHighscores (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Display configure highscores dialog. | |
| static KAction * | hint (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Give an advice/hint. | |
| static KToggleAction * | demo (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Show a demo. | |
| static KAction * | solve (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Solve the game. | |
| static KSelectAction * | chooseGameType (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Choose game type. | |
| static KAction * | restart (const QObject *recvr=0, const char *slot=0, KActionCollection *parent=0, const char *name=0L) |
| Restart game. | |
This class is an extension to the usual KStdAction class which provides easy access to often used KDE actions
Games often use different menu entries than other programs, e.g. games use the menu "game" instead of "file". This class provides the entries which differ from the usual KStdAction entries.
Definition at line 48 of file kstdgameaction.h.
|
|
The standard menubar and toolbar actions.
Definition at line 54 of file kstdgameaction.h. |
|
|
Definition at line 29 of file kstdgameaction.cpp. |
|
|
Definition at line 32 of file kstdgameaction.cpp. |
|
||||||||||||||||||||||||
|
Retrieve the action corresponding to the KStdGameAction::StdGameAction enum.
Definition at line 35 of file kstdgameaction.cpp. References create(). Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Display configure carddecks dialog.
Definition at line 189 of file kstdgameaction.cpp. References Carddecks, and create(). Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Choose game type.
Definition at line 204 of file kstdgameaction.cpp. References ChooseGameType, and create(). Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Display configure highscores dialog.
Definition at line 192 of file kstdgameaction.cpp. References ConfigureHighscores, and create(). Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Definition at line 87 of file kstdgameaction.h. |
|
||||||||||||||||||||||||
|
Creates an action corresponding to the KStdAction::StdAction enum.
Definition at line 98 of file kstdgameaction.cpp. References ChooseGameType, Demo, KStdGameActionInfo::globalAccel, LoadRecent, Pause, KStdGameActionInfo::psIconName, KStdGameActionInfo::psLabel, KStdGameActionInfo::psName, and KStdGameActionInfo::shortcut. Referenced by action(), carddecks(), chooseGameType(), configureHighscores(), demo(), end(), endTurn(), gameNew(), highscores(), hint(), load(), loadRecent(), pause(), print(), quit(), redo(), repeat(), restart(), roll(), save(), saveAs(), solve(), and undo(). |
|
||||||||||||||||||||
|
Show a demo.
Definition at line 198 of file kstdgameaction.cpp. References create(), and Demo. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
End the current game, but do not quit the program. Think of a "close" entry. Definition at line 155 of file kstdgameaction.cpp. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
End the current turn (not the game). Usually to let the next player start Definition at line 185 of file kstdgameaction.cpp. References create(), and EndTurn. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Start a new game.
Definition at line 140 of file kstdgameaction.cpp. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Show the highscores.
Definition at line 161 of file kstdgameaction.cpp. References create(), and Highscores. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Give an advice/hint.
Definition at line 195 of file kstdgameaction.cpp. References create(), and Hint. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Load a previousely saved game.
Definition at line 143 of file kstdgameaction.cpp. References create(), and Load. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Load a recently loaded game.
Definition at line 146 of file kstdgameaction.cpp. References create(), and LoadRecent. Here is the call graph for this function: ![]() |
|
|
This will return the internal name of a given standard action.
Definition at line 134 of file kstdgameaction.cpp. References KStdGameActionInfo::psName. Referenced by stdName(). |
|
||||||||||||||||||||
|
Pause the game.
Definition at line 158 of file kstdgameaction.cpp. References create(), and Pause. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Print the current screen? Game? Whatever - hardly used in games but there is at least one example (ktuberling).
Definition at line 164 of file kstdgameaction.cpp. References create(), and Print. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Quit the game.
Definition at line 167 of file kstdgameaction.cpp. References create(), and Quit. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Redo the last move (which has been undone).
Definition at line 178 of file kstdgameaction.cpp. References create(), and Redo. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Repeat the last move.
Definition at line 171 of file kstdgameaction.cpp. References create(), and Repeat. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Restart game.
Definition at line 207 of file kstdgameaction.cpp. References create(), and Restart. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Roll die or dice.
Definition at line 182 of file kstdgameaction.cpp. References create(), and Roll. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Save the current game.
Definition at line 149 of file kstdgameaction.cpp. References create(), and Save. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Save the current game under a different filename.
Definition at line 152 of file kstdgameaction.cpp. References create(), and SaveAs. Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Solve the game.
Definition at line 201 of file kstdgameaction.cpp. References create(), and Solve. Here is the call graph for this function: ![]() |
|
|
This will return the internal name of a given standard action.
Definition at line 42 of file kstdgameaction.cpp. References name(). Here is the call graph for this function: ![]() |
|
||||||||||||||||||||
|
Undo the last move.
Definition at line 174 of file kstdgameaction.cpp. References create(), and Undo. Here is the call graph for this function: ![]() |
1.4.6