1 | /* |
2 | |
3 | KDE Greeter module for xdm |
4 | |
5 | Copyright (C) 2001-2003 Oswald Buddenhagen <ossi@kde.org> |
6 | |
7 | This file contains code from the old xdm core, |
8 | Copyright 1988, 1998 Keith Packard, MIT X Consortium/The Open Group |
9 | |
10 | This program is free software; you can redistribute it and/or modify |
11 | it under the terms of the GNU General Public License as published by |
12 | the Free Software Foundation; either version 2 of the License, or |
13 | (at your option) any later version. |
14 | |
15 | This program is distributed in the hope that it will be useful, |
16 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
18 | GNU General Public License for more details. |
19 | |
20 | You should have received a copy of the GNU General Public License |
21 | along with this program; if not, write to the Free Software |
22 | Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
23 | |
24 | */ |
25 | |
26 | #ifndef _KDM_GREET_H_ |
27 | #define _KDM_GREET_H_ |
28 | |
29 | #include <greet.h> |
30 | |
31 | #ifdef __cplusplus |
32 | extern "C" { |
33 | #endif |
34 | |
35 | void gSet(int master); |
36 | void gSendInt(int val); |
37 | void gSendStr(const char *buf); |
38 | /*void gSendNStr(const char *buf, int len);*/ |
39 | void gSendArr(int len, const char *buf); |
40 | int gRecvInt(void); |
41 | char *gRecvStr(void); |
42 | char **gRecvStrArr(int *len); |
43 | char *gRecvArr(int *len); |
44 | |
45 | int getCfgInt(int id); |
46 | char *getCfgStr(int id); |
47 | char **getCfgStrArr(int id, int *len); |
48 | |
49 | void freeStrArr(char **arr); |
50 | |
51 | extern int debugLevel; |
52 | void debug(const char *fmt, ...); |
53 | void logInfo(const char *fmt, ...); |
54 | void logWarn(const char *fmt, ...); |
55 | void logError(const char *fmt, ...); |
56 | void logPanic(const char *fmt, ...) ATTR_NORETURN; |
57 | |
58 | struct _XDisplay; |
59 | |
60 | void secureKeyboard(struct _XDisplay *dpy); |
61 | void securePointer(struct _XDisplay *dpy); |
62 | void secureInputs(struct _XDisplay *dpy); |
63 | void unsecureInputs(struct _XDisplay *dpy); |
64 | void secureDisplay(struct _XDisplay *dpy); |
65 | void unsecureDisplay(struct _XDisplay *dpy); |
66 | int pingServer(struct _XDisplay *dpy); |
67 | |
68 | void setupModifiers(struct _XDisplay *mdpy, int numlock); |
69 | void restoreModifiers(void); |
70 | |
71 | void setCursor(struct _XDisplay *mdpy, int window, int shape); |
72 | |
73 | |
74 | extern int rfd; /* for select() loops */ |
75 | extern int mrfd, mwfd, srfd, swfd; /* for main */ |
76 | |
77 | extern char *dname; /* d->name */ |
78 | |
79 | #ifdef __cplusplus |
80 | } |
81 | #endif |
82 | |
83 | #endif /* _KDM_GREET_H_ */ |
84 | |