blob: 6389a7c8d78733cd379c9b5aeb36a2bb23035ecf (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#ifndef _X11_UTIL_H_
#define _X11_UTIL_H_
#include <stdbool.h>
#include <time.h>
#define SAVER_OFF (0)
#define SAVER_ACTIVE (1)
#define SAVER_LOCKED (2)
#define SCREEN_UNKNOWN (0)
#define SCREEN_ON (1)
#define SCREEN_OFF (2)
struct x11state {
time_t lockTimestamp;
int idleSeconds;
int saverState;
int screenStandby;
};
bool getX11IdleTimes( const char *xauth, const char *display, struct x11state *state );
void setScreenDpms( const char *xauth, const char *display, int mode );
void enableScreenSaver( const char *xauth, const char *display, const int state );
#endif
|