23 #ifndef _LAX_LAXDEVICES_H
24 #define _LAX_LAXDEVICES_H
26 #ifdef _LAX_PLATFORM_XLIB
28 #include <X11/Xft/Xft.h>
29 #include <X11/Xutil.h>
30 #ifdef LAX_USES_XINPUT2
31 #include <X11/extensions/XInput2.h>
33 #include <X11/extensions/XInput.h>
34 #include <X11/extensions/XIproto.h>
35 #endif //LAX_USES_XINPUT2
36 #endif //_LAX_PLATFORM_XLIB
38 #include <lax/events.h>
39 #include <lax/lists.h>
73 virtual double GetValue(
int v,
int w);
76 virtual int getFieldTypeInfo(
int f,
const char **nme,
int *type,
int *min,
int *max,
int *res);
87 virtual const char *
Name(
const char *nname);
102 unsigned long last_leave_window;
114 virtual void buttonPressed(Time time,
int button,
unsigned long windowid);
121 int *x,
int *y,
unsigned int *mods,
122 double *pressure,
double *tiltx,
double *tilty)=0;
123 virtual int Pressure();
139 virtual unsigned long QueryModifiers();
164 virtual int NumDevices() {
return devices.
n; }
165 virtual LaxDevice *Device(
int i) {
return (i>=0 && i<devices.
n-1) ? devices.
e[i] : NULL; }
182 virtual int usesX() {
return 1; }
190 int *x,
int *y,
unsigned int *mods,
191 double *pressure,
double *tiltx,
double *tilty);
200 virtual int usesX() {
return 1; }
209 #ifdef LAX_USES_XINPUT2
211 DeviceManager *newXInput2DeviceManager(Display *dpy,
int which);
220 virtual int usesX() {
return 1; }
221 virtual int eventFilter(EventData **events_ret,XEvent *xev,anXWindow *target,
int &isinput);
222 virtual int selectForWindow(anXWindow *win,
unsigned long);
223 virtual int setMouseShape(anXWindow *win,
int shape);
224 virtual int grabDevice(anXWindow *win);
225 virtual int ungrabDevice();
226 virtual int getInfo(anXWindow *win,
227 int *screen, anXWindow **child,
228 int *x,
int *y,
unsigned int *mods,
229 double *pressure,
double *tiltx,
double *tilty);
239 virtual int usesX() {
return 1; }
240 virtual int selectForWindow(anXWindow *win,
unsigned long);
241 virtual int eventFilter(EventData **events_ret, XEvent *xev, anXWindow *ww,
int &isinput);
242 virtual int SetFocus(anXWindow *win, clock_t t,
int notifyonly);
247 #endif //LAX_USES_XINPUT2