1
0
mirror of git://projects.qi-hardware.com/gmenu2x.git synced 2024-12-28 20:18:57 +02:00
gmenu2x/src/powersaver.h

27 lines
593 B
C++

#ifndef POWERSAVER_H
#define POWERSAVER_H
#include <SDL.h>
class PowerSaver {
public:
static PowerSaver* getInstance();
static bool isRunning();
~PowerSaver();
void addScreenTimer();
void resetScreenTimer();
void enableScreen();
void disableScreen();
void setScreenTimeout( unsigned int seconds );
private:
PowerSaver( );
static PowerSaver* instance;
bool screenState;
unsigned int screenTimeout;
SDL_TimerID screenTimer;
void setScreenBlanking( bool state );
};
#endif