#undef class
}
-#if XORG < 19
-static int vncXkbScreenPrivateKeyIndex;
-static DevPrivateKey vncXkbScreenPrivateKey = &vncXkbScreenPrivateKeyIndex;
-#else
-static DevPrivateKeyRec vncXkbPrivateKeyRec;
-#define vncXkbScreenPrivateKey (&vncXkbPrivateKeyRec)
-#endif
-
-#define vncXkbScreenPrivate(pScreen) \
- (*(InputDevice**) dixLookupPrivate(&(pScreen)->devPrivates, \
- vncXkbScreenPrivateKey))
-
#ifndef KEYBOARD_OR_FLOAT
#define KEYBOARD_OR_FLOAT MASTER_KEYBOARD
#endif
void InputDevice::PrepareInputDevices(void)
{
-#if XORG < 19
- if (!dixRequestPrivate(vncXkbScreenPrivateKey, sizeof(InputDevice*)))
- FatalError("Failed to register TigerVNC XKB screen key\n");
-#else
- if (!dixRegisterPrivateKey(vncXkbScreenPrivateKey, PRIVATE_SCREEN,
- sizeof(InputDevice*)))
- FatalError("Failed to register TigerVNC XKB screen key\n");
-#endif
-
- for (int scr = 0; scr < screenInfo.numScreens; scr++)
- vncXkbScreenPrivate(screenInfo.screens[scr]) = this;
-
/*
* Not ideal since these callbacks do not stack, but it's the only
* decent way we can reliably catch events for both the slave and
InternalEvent *event,
DeviceIntPtr dev)
{
- InputDevice *self = vncXkbScreenPrivate(screenInfo.screens[screenNum]);
unsigned int backupctrls;
- if (event->device_event.sourceid == self->keyboardDev->id) {
+ if (event->device_event.sourceid == singleton.keyboardDev->id) {
XkbControlsPtr ctrls;
/*
dev->c_public.processInputProc(event, dev);
- if (event->device_event.sourceid == self->keyboardDev->id) {
+ if (event->device_event.sourceid == singleton.keyboardDev->id) {
XkbControlsPtr ctrls;
ctrls = dev->key->xkbInfo->desc->ctrls;