Photon microGUI widgets library 0.6.0
|
#include <PhWidgetsNativeTypes.h>
Hotkey handler structure.
The PtHotkeyCallback_t structure lets you specify hotkeys or hotkey handlers, or both, for various widgets. This structure contains at least:
unsigned short key_sym_cap Depending on the specified flags, this member contains either the symbol or cap of the key to be interpreted as a hotkey. For valid key_sym_cap values, see
<photon/PkKeyDef.h>
.
short flags Determines how key_sym_cap is interpreted and whether or not key_mods is used.
unsigned long key_mods Key modifiers that must be active for the key to be considered a hotkey.
PtWidget_t *widget If
event_f
is NULL, the widget member's activate callback is invoked with a reason_subtype ofPt_CB_HOTKEY
. If thewidget
member is NULL when the hotkey is attached, it's set to the widget that the hotkey is attached to.
void *data A pointer to any data that you want to pass as the second argument to the callback function.
int (*event_f)( PtWidget_t *, void *, PtCallbackInfo_t * ) A pointer to the hotkey function. If
event_f
is NULL when the hotkey is activated, the widget that the hotkey is attached to has its PhWidgets::Basic::Activate invoked with a reason_subtype ofPt_CB_HOTKEY
.