Implementation for the gameMenu
event vector.
More...
#include <sifteo/event.h>
Public Member Functions | |
void * | context () const |
Return the currently set context object, as a void pointer. | |
void * | handler () const |
Return the currently set handler function, as a void pointer. | |
template<typename tContext > | |
void | set (void(*handler)(tContext), tContext context, const char *label=0) const |
Set this Vector to a function with context pointer. More... | |
void | set (void(*handler)(void *), const char *label=0) const |
Set this Vector to a bare function. More... | |
template<typename tClass > | |
void | set (void(tClass::*handler)(), tClass *cls, const char *label=0) const |
Set this event vector to an instance method, given a class method pointer and an instance of that class. More... | |
void | setLabel (const char *label) const |
Set the label text used for the Game Menu item. More... | |
void | setResumeEnabled (bool enabled) const |
Specify whether the 'Resume' option should be included in the menu. More... | |
void | unset () const |
Disable this event vector, and disable the game menu. More... | |
Implementation for the gameMenu
event vector.
An instance of this class is found in the Events namespace. Typically you should not create instances of this object elsewhere.
|
inline |
Set this Vector to a function with context pointer.
Requires a closure consisting of an arbitrary pointer-sized context value, and a function pointer of the form:
void handler(ContextType c);
This can set the item's label at the same time. See setLabel() for details about the suggested label format.
|
inline |
Set this Vector to a bare function.
Set this event vector to a bare function which requires no context. It must still take a dummy void* placeholder argument:
void handler(void*);
This can set the item's label at the same time. See setLabel() for details about the suggested label format.
|
inline |
Set this event vector to an instance method, given a class method pointer and an instance of that class.
This can set the item's label at the same time. See setLabel() for details about the suggested label format.
|
inline |
Set the label text used for the Game Menu item.
This sets the text which is displayed under the Game Menu icon on the standard Pause menu. It must be between 1 and 15 characters long, and we strongly recommend that it is an even number of characters, so that it can be centered perfectly.
The character set is that of the font in BG0_ROM. It is a superset of ASCII, with nearly all ISO Latin-1 characters.
|
inline |
Specify whether the 'Resume' option should be included in the menu.
|
inline |
Disable this event vector, and disable the game menu.
The custom menu item will no longer appear on the Pause menu.
Sifteo SDK v1.1.0 (see all versions)
Last updated Tue Dec 23 2014, by Doxygen