Go to the source code of this file.
Typedef Documentation
Function Documentation
Get the current power supply details.
- Parameters
-
| secs | Seconds of battery life left. You can pass a NULL here if you don't care. Will return -1 if we can't determine a value, or we're not running on a battery. |
| pct | Percentage of battery life left, between 0 and 100. You can pass a NULL here if you don't care. Will return -1 if we can't determine a value, or we're not running on a battery. |
- Returns
- The state of the battery (if any).
Definition at line 85 of file SDL_power.c.
References i, implementations, NULL, retval, and SDL_POWERSTATE_UNKNOWN.
{
#ifndef SDL_POWER_DISABLED
#endif
int _seconds, _percent;
seconds = &_seconds;
}
percent = &_percent;
}
#ifndef SDL_POWER_DISABLED
for (i = 0; i < total; i++) {
}
}
#endif
*seconds = -1;
*percent = -1;
}
Variable Documentation