#include <revolution/os.h> typedef void (*OSPowerCallback)(void); OSPowerCallback OSSetPowerCallback(OSPowerCallback callback);
| callback | Pointer to the callback function called at time of power button input. |
|---|
Returns a pointer to a previously set callback function.
Registers a one-time power button callback. The callback function is called only once when the Power Button on the console is pressed or when the Power Button on the paired Wii Remote is held down, and then callback registration is automatically deleted. In principle, the application receiving the power button callback must execute shutdown procedures within a set amount of time.
Note:
2010/05/28 Added a link for more information to the note regarding the failure to call the registered callback.
2006/08/30 Added a description about the Power Button on the Wii Remote.
2006/08/10 Initial version.
CONFIDENTIAL