41 #ifndef SDL_POWER_DISABLED
42 #ifdef SDL_POWER_HARDWIRED
45 SDL_GetPowerInfo_Hardwired(
SDL_PowerState * state,
int *seconds,
int *percent)
57 #ifndef SDL_POWER_DISABLED
58 #ifdef SDL_POWER_LINUX
62 #ifdef SDL_POWER_WINDOWS
65 #ifdef SDL_POWER_UIKIT
68 #ifdef SDL_POWER_MACOSX
74 #ifdef SDL_POWER_ANDROID
81 #ifdef SDL_POWER_HARDWIRED
82 SDL_GetPowerInfo_Hardwired,
91 int _seconds, _percent;
96 if (seconds ==
NULL) {
100 if (percent ==
NULL) {
104 for (i = 0; i < total; i++) {
105 if (implementations[i] (&retval, seconds, percent)) {
SDL_bool SDL_GetPowerInfo_BeOS(SDL_PowerState *, int *, int *)
SDL_bool SDL_GetPowerInfo_PSP(SDL_PowerState *, int *, int *)
SDL_bool SDL_GetPowerInfo_UIKit(SDL_PowerState *, int *, int *)
SDL_bool SDL_GetPowerInfo_Linux_proc_apm(SDL_PowerState *, int *, int *)
SDL_bool(* SDL_GetPowerInfo_Impl)(SDL_PowerState *state, int *seconds, int *percent)
SDL_bool SDL_GetPowerInfo_Windows(SDL_PowerState *, int *, int *)
static SDL_GetPowerInfo_Impl implementations[]
SDL_bool SDL_GetPowerInfo_Android(SDL_PowerState *, int *, int *)
SDL_PowerState
The basic state for the system's power supply.
SDL_bool SDL_GetPowerInfo_MacOSX(SDL_PowerState *, int *, int *)
DECLSPEC SDL_PowerState SDLCALL SDL_GetPowerInfo(int *secs, int *pct)
Get the current power supply details.
SDL_bool SDL_GetPowerInfo_Linux_proc_acpi(SDL_PowerState *, int *, int *)