Merge remote-tracking branch 'whot/for-keith'
This commit is contained in:
commit
d4096abb59
|
@ -679,12 +679,19 @@ GetXTestDevice(DeviceIntPtr master)
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
XTestExtensionTearDown(ExtensionEntry *e)
|
||||||
|
{
|
||||||
|
FreeEventList(xtest_evlist, GetMaximumEventsNum());
|
||||||
|
xtest_evlist = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
XTestExtensionInit(INITARGS)
|
XTestExtensionInit(INITARGS)
|
||||||
{
|
{
|
||||||
AddExtension(XTestExtensionName, 0, 0,
|
AddExtension(XTestExtensionName, 0, 0,
|
||||||
ProcXTestDispatch, SProcXTestDispatch,
|
ProcXTestDispatch, SProcXTestDispatch,
|
||||||
NULL, StandardMinorOpcode);
|
XTestExtensionTearDown, StandardMinorOpcode);
|
||||||
|
|
||||||
xtest_evlist = InitEventList(GetMaximumEventsNum());
|
xtest_evlist = InitEventList(GetMaximumEventsNum());
|
||||||
}
|
}
|
||||||
|
|
|
@ -386,8 +386,9 @@ BlockHandler(pointer pTimeout, pointer pReadmask)
|
||||||
screenInfo.screens[i]->blockData,
|
screenInfo.screens[i]->blockData,
|
||||||
pTimeout, pReadmask);
|
pTimeout, pReadmask);
|
||||||
for (i = 0; i < numHandlers; i++)
|
for (i = 0; i < numHandlers; i++)
|
||||||
(*handlers[i].BlockHandler) (handlers[i].blockData,
|
if (!handlers[i].deleted)
|
||||||
pTimeout, pReadmask);
|
(*handlers[i].BlockHandler) (handlers[i].blockData,
|
||||||
|
pTimeout, pReadmask);
|
||||||
if (handlerDeleted)
|
if (handlerDeleted)
|
||||||
{
|
{
|
||||||
for (i = 0; i < numHandlers;)
|
for (i = 0; i < numHandlers;)
|
||||||
|
@ -416,8 +417,9 @@ WakeupHandler(int result, pointer pReadmask)
|
||||||
|
|
||||||
++inHandler;
|
++inHandler;
|
||||||
for (i = numHandlers - 1; i >= 0; i--)
|
for (i = numHandlers - 1; i >= 0; i--)
|
||||||
(*handlers[i].WakeupHandler) (handlers[i].blockData,
|
if (!handlers[i].deleted)
|
||||||
result, pReadmask);
|
(*handlers[i].WakeupHandler) (handlers[i].blockData,
|
||||||
|
result, pReadmask);
|
||||||
for (i = 0; i < screenInfo.numScreens; i++)
|
for (i = 0; i < screenInfo.numScreens; i++)
|
||||||
(* screenInfo.screens[i]->WakeupHandler)(i,
|
(* screenInfo.screens[i]->WakeupHandler)(i,
|
||||||
screenInfo.screens[i]->wakeupData,
|
screenInfo.screens[i]->wakeupData,
|
||||||
|
|
|
@ -320,6 +320,8 @@ updateSlaveDeviceCoords(DeviceIntPtr master, DeviceIntPtr pDev)
|
||||||
* position of the pointer */
|
* position of the pointer */
|
||||||
pDev->last.valuators[0] = master->last.valuators[0];
|
pDev->last.valuators[0] = master->last.valuators[0];
|
||||||
pDev->last.valuators[1] = master->last.valuators[1];
|
pDev->last.valuators[1] = master->last.valuators[1];
|
||||||
|
pDev->last.remainder[0] = master->last.remainder[0];
|
||||||
|
pDev->last.remainder[1] = master->last.remainder[1];
|
||||||
|
|
||||||
if (!pDev->valuator)
|
if (!pDev->valuator)
|
||||||
return;
|
return;
|
||||||
|
@ -339,14 +341,19 @@ updateSlaveDeviceCoords(DeviceIntPtr master, DeviceIntPtr pDev)
|
||||||
if ((lastSlave = master->last.slave) && lastSlave->valuator) {
|
if ((lastSlave = master->last.slave) && lastSlave->valuator) {
|
||||||
for (i = 2; i < pDev->valuator->numAxes; i++) {
|
for (i = 2; i < pDev->valuator->numAxes; i++) {
|
||||||
if (i >= lastSlave->valuator->numAxes)
|
if (i >= lastSlave->valuator->numAxes)
|
||||||
|
{
|
||||||
pDev->last.valuators[i] = 0;
|
pDev->last.valuators[i] = 0;
|
||||||
|
pDev->last.remainder[i] = 0;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
pDev->last.valuators[i] =
|
pDev->last.valuators[i] =
|
||||||
rescaleValuatorAxis(pDev->last.valuators[i],
|
rescaleValuatorAxis(pDev->last.valuators[i],
|
||||||
pDev->last.remainder[i],
|
pDev->last.remainder[i],
|
||||||
&pDev->last.remainder[i],
|
&pDev->last.remainder[i],
|
||||||
lastSlave->valuator->axes + i,
|
lastSlave->valuator->axes + i,
|
||||||
pDev->valuator->axes + i, 0);
|
pDev->valuator->axes + i, 0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1164,14 +1171,17 @@ GetPointerEvents(InternalEvent *events, DeviceIntPtr pDev, int type, int buttons
|
||||||
|
|
||||||
events = UpdateFromMaster(events, pDev, DEVCHANGE_POINTER_EVENT, &num_events);
|
events = UpdateFromMaster(events, pDev, DEVCHANGE_POINTER_EVENT, &num_events);
|
||||||
|
|
||||||
raw = &events->raw_event;
|
|
||||||
events++;
|
|
||||||
num_events++;
|
|
||||||
|
|
||||||
valuator_mask_copy(&mask, mask_in);
|
valuator_mask_copy(&mask, mask_in);
|
||||||
|
|
||||||
init_raw(pDev, raw, ms, type, buttons);
|
if ((flags & POINTER_NORAW) == 0)
|
||||||
set_raw_valuators(raw, &mask, raw->valuators.data_raw);
|
{
|
||||||
|
raw = &events->raw_event;
|
||||||
|
events++;
|
||||||
|
num_events++;
|
||||||
|
|
||||||
|
init_raw(pDev, raw, ms, type, buttons);
|
||||||
|
set_raw_valuators(raw, &mask, raw->valuators.data_raw);
|
||||||
|
}
|
||||||
|
|
||||||
if (flags & POINTER_ABSOLUTE)
|
if (flags & POINTER_ABSOLUTE)
|
||||||
{
|
{
|
||||||
|
@ -1210,7 +1220,8 @@ GetPointerEvents(InternalEvent *events, DeviceIntPtr pDev, int type, int buttons
|
||||||
moveRelative(pDev, &x, &y, &mask);
|
moveRelative(pDev, &x, &y, &mask);
|
||||||
}
|
}
|
||||||
|
|
||||||
set_raw_valuators(raw, &mask, raw->valuators.data);
|
if ((flags & POINTER_NORAW) == 0)
|
||||||
|
set_raw_valuators(raw, &mask, raw->valuators.data);
|
||||||
|
|
||||||
positionSprite(pDev, (flags & POINTER_ABSOLUTE) ? Absolute : Relative,
|
positionSprite(pDev, (flags & POINTER_ABSOLUTE) ? Absolute : Relative,
|
||||||
&x, &y, x_frac, y_frac, scr, &cx, &cy, &cx_frac, &cy_frac);
|
&x, &y, x_frac, y_frac, scr, &cx, &cy, &cx_frac, &cy_frac);
|
||||||
|
|
112
dix/grabs.c
112
dix/grabs.c
|
@ -68,6 +68,118 @@ SOFTWARE.
|
||||||
#define BITCLEAR(buf, i) MASKWORD(buf, i) &= ~BITMASK(i)
|
#define BITCLEAR(buf, i) MASKWORD(buf, i) &= ~BITMASK(i)
|
||||||
#define GETBIT(buf, i) (MASKWORD(buf, i) & BITMASK(i))
|
#define GETBIT(buf, i) (MASKWORD(buf, i) & BITMASK(i))
|
||||||
|
|
||||||
|
void
|
||||||
|
PrintDeviceGrabInfo(DeviceIntPtr dev)
|
||||||
|
{
|
||||||
|
ClientPtr client;
|
||||||
|
LocalClientCredRec *lcc;
|
||||||
|
int i, j;
|
||||||
|
GrabInfoPtr devGrab = &dev->deviceGrab;
|
||||||
|
GrabPtr grab = devGrab->grab;
|
||||||
|
|
||||||
|
ErrorF("Active grab 0x%lx (%s) on device '%s' (%d):",
|
||||||
|
(unsigned long) grab->resource,
|
||||||
|
(grab->grabtype == GRABTYPE_XI2) ? "xi2" :
|
||||||
|
((grab->grabtype == GRABTYPE_CORE) ? "core" : "xi1"),
|
||||||
|
dev->name, dev->id);
|
||||||
|
|
||||||
|
client = clients[CLIENT_ID(grab->resource)];
|
||||||
|
if (client && GetLocalClientCreds(client, &lcc) != -1)
|
||||||
|
{
|
||||||
|
ErrorF(" client pid %ld uid %ld gid %ld\n",
|
||||||
|
(lcc->fieldsSet & LCC_PID_SET) ? (long) lcc->pid : 0,
|
||||||
|
(lcc->fieldsSet & LCC_UID_SET) ? (long) lcc->euid : 0,
|
||||||
|
(lcc->fieldsSet & LCC_GID_SET) ? (long) lcc->egid : 0);
|
||||||
|
FreeLocalClientCreds(lcc);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ErrorF(" (no client information available)\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
/* XXX is this even correct? */
|
||||||
|
if (devGrab->sync.other)
|
||||||
|
ErrorF(" grab ID 0x%lx from paired device\n",
|
||||||
|
(unsigned long) devGrab->sync.other->resource);
|
||||||
|
|
||||||
|
ErrorF(" at %ld (from %s grab)%s (device %s, state %d)\n",
|
||||||
|
(unsigned long) devGrab->grabTime.milliseconds,
|
||||||
|
devGrab->fromPassiveGrab ? "passive" : "active",
|
||||||
|
devGrab->implicitGrab ? " (implicit)" : "",
|
||||||
|
devGrab->sync.frozen ? "frozen" : "thawed",
|
||||||
|
devGrab->sync.state);
|
||||||
|
|
||||||
|
if (grab->grabtype == GRABTYPE_CORE)
|
||||||
|
{
|
||||||
|
ErrorF(" core event mask 0x%lx\n",
|
||||||
|
(unsigned long) grab->eventMask);
|
||||||
|
}
|
||||||
|
else if (grab->grabtype == GRABTYPE_XI)
|
||||||
|
{
|
||||||
|
ErrorF(" xi1 event mask 0x%lx\n",
|
||||||
|
devGrab->implicitGrab ? (unsigned long) grab->deviceMask :
|
||||||
|
(unsigned long) grab->eventMask);
|
||||||
|
}
|
||||||
|
else if (grab->grabtype == GRABTYPE_XI2)
|
||||||
|
{
|
||||||
|
for (i = 0; i < EMASKSIZE; i++)
|
||||||
|
{
|
||||||
|
int print;
|
||||||
|
print = 0;
|
||||||
|
for (j = 0; j < XI2MASKSIZE; j++)
|
||||||
|
{
|
||||||
|
if (grab->xi2mask[i][j])
|
||||||
|
{
|
||||||
|
print = 1;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!print)
|
||||||
|
continue;
|
||||||
|
ErrorF(" xi2 event mask for device %d: 0x", dev->id);
|
||||||
|
for (j = 0; j < XI2MASKSIZE; j++)
|
||||||
|
ErrorF("%x", grab->xi2mask[i][j]);
|
||||||
|
ErrorF("\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (devGrab->fromPassiveGrab)
|
||||||
|
{
|
||||||
|
ErrorF(" passive grab type %d, detail 0x%x, "
|
||||||
|
"activating key %d\n", grab->type, grab->detail.exact,
|
||||||
|
devGrab->activatingKey);
|
||||||
|
}
|
||||||
|
|
||||||
|
ErrorF(" owner-events %s, kb %d ptr %d, confine %lx, cursor 0x%lx\n",
|
||||||
|
grab->ownerEvents ? "true" : "false",
|
||||||
|
grab->keyboardMode, grab->pointerMode,
|
||||||
|
grab->confineTo ? (unsigned long) grab->confineTo->drawable.id : 0,
|
||||||
|
grab->cursor ? (unsigned long) grab->cursor->id : 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
UngrabAllDevices(Bool kill_client)
|
||||||
|
{
|
||||||
|
DeviceIntPtr dev;
|
||||||
|
ClientPtr client;
|
||||||
|
|
||||||
|
ErrorF("Ungrabbing all devices%s; grabs listed below:\n",
|
||||||
|
kill_client ? " and killing their owners" : "");
|
||||||
|
|
||||||
|
for (dev = inputInfo.devices; dev; dev = dev->next)
|
||||||
|
{
|
||||||
|
if (!dev->deviceGrab.grab)
|
||||||
|
continue;
|
||||||
|
PrintDeviceGrabInfo(dev);
|
||||||
|
client = clients[CLIENT_ID(dev->deviceGrab.grab->resource)];
|
||||||
|
if (!client || client->clientGone)
|
||||||
|
dev->deviceGrab.DeactivateGrab(dev);
|
||||||
|
CloseDownClient(client);
|
||||||
|
}
|
||||||
|
|
||||||
|
ErrorF("End list of ungrabbed devices\n");
|
||||||
|
}
|
||||||
|
|
||||||
GrabPtr
|
GrabPtr
|
||||||
CreateGrab(
|
CreateGrab(
|
||||||
int client,
|
int client,
|
||||||
|
|
141
dix/window.c
141
dix/window.c
|
@ -108,6 +108,7 @@ Equipment Corporation.
|
||||||
#include "regionstr.h"
|
#include "regionstr.h"
|
||||||
#include "validate.h"
|
#include "validate.h"
|
||||||
#include "windowstr.h"
|
#include "windowstr.h"
|
||||||
|
#include "propertyst.h"
|
||||||
#include "input.h"
|
#include "input.h"
|
||||||
#include "inputstr.h"
|
#include "inputstr.h"
|
||||||
#include "resource.h"
|
#include "resource.h"
|
||||||
|
@ -124,10 +125,13 @@ Equipment Corporation.
|
||||||
#include "dixevents.h"
|
#include "dixevents.h"
|
||||||
#include "globals.h"
|
#include "globals.h"
|
||||||
#include "mi.h" /* miPaintWindow */
|
#include "mi.h" /* miPaintWindow */
|
||||||
|
#include "compint.h"
|
||||||
|
|
||||||
#include "privates.h"
|
#include "privates.h"
|
||||||
#include "xace.h"
|
#include "xace.h"
|
||||||
|
|
||||||
|
#include <X11/Xatom.h> /* must come after server includes */
|
||||||
|
|
||||||
/******
|
/******
|
||||||
* Window stuff for server
|
* Window stuff for server
|
||||||
*
|
*
|
||||||
|
@ -176,46 +180,129 @@ static Bool TileScreenSaver(ScreenPtr pScreen, int kind);
|
||||||
|
|
||||||
#define SubStrSend(pWin,pParent) (StrSend(pWin) || SubSend(pParent))
|
#define SubStrSend(pWin,pParent) (StrSend(pWin) || SubSend(pParent))
|
||||||
|
|
||||||
#ifdef DEBUG
|
static const char *overlay_win_name = "<composite overlay>";
|
||||||
/******
|
|
||||||
* PrintWindowTree
|
|
||||||
* For debugging only
|
|
||||||
******/
|
|
||||||
|
|
||||||
static void
|
static const char *
|
||||||
PrintChildren(WindowPtr p1, int indent)
|
get_window_name(WindowPtr pWin)
|
||||||
{
|
{
|
||||||
WindowPtr p2;
|
#define WINDOW_NAME_BUF_LEN 512
|
||||||
int i;
|
PropertyPtr prop;
|
||||||
|
CompScreenPtr comp_screen = GetCompScreen(pWin->drawable.pScreen);
|
||||||
|
static char buf[WINDOW_NAME_BUF_LEN];
|
||||||
|
int len;
|
||||||
|
|
||||||
while (p1)
|
if (comp_screen && pWin == comp_screen->pOverlayWin)
|
||||||
|
return overlay_win_name;
|
||||||
|
|
||||||
|
for (prop = wUserProps(pWin); prop; prop = prop->next)
|
||||||
{
|
{
|
||||||
p2 = p1->firstChild;
|
if (prop->propertyName == XA_WM_NAME && prop->type == XA_STRING &&
|
||||||
ErrorF("[dix] ");
|
prop->data)
|
||||||
for (i=0; i<indent; i++) ErrorF(" ");
|
{
|
||||||
ErrorF("%lx\n", p1->drawable.id);
|
len = min(prop->size, WINDOW_NAME_BUF_LEN - 1);
|
||||||
RegionPrint(&p1->clipList);
|
memcpy(buf, prop->data, len);
|
||||||
PrintChildren(p2, indent+4);
|
buf[len] = '\0';
|
||||||
p1 = p1->nextSib;
|
return buf;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return NULL;
|
||||||
|
#undef WINDOW_NAME_BUF_LEN
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void log_window_info(WindowPtr pWin, int depth)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
const char *win_name, *visibility;
|
||||||
|
BoxPtr rects;
|
||||||
|
ScreenPtr pScreen = pWin->drawable.pScreen;
|
||||||
|
|
||||||
|
for (i = 0; i < (depth << 2); i++)
|
||||||
|
ErrorF(" ");
|
||||||
|
|
||||||
|
win_name = get_window_name(pWin);
|
||||||
|
ErrorF("win 0x%.8x (%s), [%d, %d] to [%d, %d]",
|
||||||
|
pWin->drawable.id,
|
||||||
|
win_name ? win_name : "no name",
|
||||||
|
pWin->drawable.x, pWin->drawable.y,
|
||||||
|
pWin->drawable.x + pWin->drawable.width,
|
||||||
|
pWin->drawable.y + pWin->drawable.height);
|
||||||
|
|
||||||
|
if (pWin->overrideRedirect)
|
||||||
|
ErrorF(" (override redirect)");
|
||||||
|
if (pWin->redirectDraw)
|
||||||
|
ErrorF(" (%s compositing: pixmap %x)",
|
||||||
|
(pWin->redirectDraw == RedirectDrawAutomatic) ?
|
||||||
|
"automatic" : "manual",
|
||||||
|
pScreen->GetWindowPixmap(pWin)->drawable.id);
|
||||||
|
|
||||||
|
switch (pWin->visibility)
|
||||||
|
{
|
||||||
|
case VisibilityUnobscured:
|
||||||
|
visibility = "unobscured";
|
||||||
|
break;
|
||||||
|
case VisibilityPartiallyObscured:
|
||||||
|
visibility = "partially obscured";
|
||||||
|
break;
|
||||||
|
case VisibilityFullyObscured:
|
||||||
|
visibility = "fully obscured";
|
||||||
|
break;
|
||||||
|
case VisibilityNotViewable:
|
||||||
|
visibility = "unviewable";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
ErrorF(", %s", visibility);
|
||||||
|
|
||||||
|
if (REGION_NOTEMPTY(pScreen, &pWin->clipList))
|
||||||
|
{
|
||||||
|
ErrorF(", clip list:");
|
||||||
|
rects = REGION_RECTS(&pWin->clipList);
|
||||||
|
for (i = 0; i < REGION_NUM_RECTS(&pWin->clipList); i++)
|
||||||
|
ErrorF(" [(%d, %d) to (%d, %d)]",
|
||||||
|
rects[i].x1, rects[i].y1,
|
||||||
|
rects[i].x2, rects[i].y2);
|
||||||
|
ErrorF("; extents [(%d, %d) to (%d, %d)]",
|
||||||
|
pWin->clipList.extents.x1, pWin->clipList.extents.y1,
|
||||||
|
pWin->clipList.extents.x2, pWin->clipList.extents.y2);
|
||||||
|
}
|
||||||
|
|
||||||
|
ErrorF("\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
PrintWindowTree(void)
|
PrintWindowTree(void)
|
||||||
{
|
{
|
||||||
int i;
|
int scrnum, depth;
|
||||||
WindowPtr pWin, p1;
|
ScreenPtr pScreen;
|
||||||
|
WindowPtr pWin;
|
||||||
|
|
||||||
for (i=0; i<screenInfo.numScreens; i++)
|
for (scrnum = 0; scrnum < screenInfo.numScreens; scrnum++)
|
||||||
{
|
{
|
||||||
ErrorF("[dix] WINDOW %d\n", i);
|
pScreen = screenInfo.screens[scrnum];
|
||||||
pWin = screenInfo.screens[i]->root;
|
ErrorF("[dix] Dumping windows for screen %d (pixmap %x):\n", scrnum,
|
||||||
RegionPrint(&pWin->clipList);
|
pScreen->GetScreenPixmap(pScreen)->drawable.id);
|
||||||
p1 = pWin->firstChild;
|
pWin = pScreen->root;
|
||||||
PrintChildren(p1, 4);
|
depth = 1;
|
||||||
|
while (pWin)
|
||||||
|
{
|
||||||
|
log_window_info(pWin, depth);
|
||||||
|
if (pWin->firstChild)
|
||||||
|
{
|
||||||
|
pWin = pWin->firstChild;
|
||||||
|
depth++;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
while (pWin && !pWin->nextSib)
|
||||||
|
{
|
||||||
|
pWin = pWin->parent;
|
||||||
|
depth--;
|
||||||
|
}
|
||||||
|
if (!pWin)
|
||||||
|
break;
|
||||||
|
pWin = pWin->nextSib;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
int
|
int
|
||||||
TraverseTree(WindowPtr pWin, VisitWindowProcPtr func, pointer data)
|
TraverseTree(WindowPtr pWin, VisitWindowProcPtr func, pointer data)
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2001 Keith Packard
|
* Copyright © 2001 Keith Packard
|
||||||
*
|
*
|
||||||
* Partly based on code that is Copyright © The XFree86 Project Inc.
|
* Partly based on code that is Copyright © The XFree86 Project Inc.
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2001 Keith Packard
|
* Copyright © 2001 Keith Packard
|
||||||
*
|
*
|
||||||
* Partly based on code that is Copyright © The XFree86 Project Inc.
|
* Partly based on code that is Copyright © The XFree86 Project Inc.
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
@ -23,7 +23,7 @@
|
||||||
*
|
*
|
||||||
* Authors:
|
* Authors:
|
||||||
* Eric Anholt <eric@anholt.net>
|
* Eric Anholt <eric@anholt.net>
|
||||||
* Michel Dänzer <michel@tungstengraphics.com>
|
* Michel Dänzer <michel@tungstengraphics.com>
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2009 Maarten Maathuis
|
* Copyright © 2009 Maarten Maathuis
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2009 Maarten Maathuis
|
* Copyright © 2009 Maarten Maathuis
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2006 Intel Corporation
|
* Copyright © 2006 Intel Corporation
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
@ -22,7 +22,7 @@
|
||||||
*
|
*
|
||||||
* Authors:
|
* Authors:
|
||||||
* Eric Anholt <eric@anholt.net>
|
* Eric Anholt <eric@anholt.net>
|
||||||
* Michel Dänzer <michel@tungstengraphics.com>
|
* Michel Dänzer <michel@tungstengraphics.com>
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2009 Maarten Maathuis
|
* Copyright © 2009 Maarten Maathuis
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2009 Maarten Maathuis
|
* Copyright © 2009 Maarten Maathuis
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/*
|
/*
|
||||||
*
|
*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -77,6 +77,7 @@ void InitInput(int argc, char **argv)
|
||||||
|
|
||||||
void CloseInput(void)
|
void CloseInput(void)
|
||||||
{
|
{
|
||||||
|
mieqFini();
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Called from dix/dispatch.c in Dispatch() whenever input events
|
/** Called from dix/dispatch.c in Dispatch() whenever input events
|
||||||
|
|
|
@ -546,9 +546,6 @@ static void dmxProcessInputEvents(DMXInputInfo *dmxInput)
|
||||||
return;
|
return;
|
||||||
for (i = 0; i < dmxInput->numDevs; i += dmxInput->devs[i]->binding)
|
for (i = 0; i < dmxInput->numDevs; i += dmxInput->devs[i]->binding)
|
||||||
if (dmxInput->devs[i]->process_input) {
|
if (dmxInput->devs[i]->process_input) {
|
||||||
#if 11 /*BP*/
|
|
||||||
miPointerUpdateSprite(dmxInput->devs[i]->pDevice);
|
|
||||||
#endif
|
|
||||||
dmxInput->devs[i]->process_input(dmxInput->devs[i]->private);
|
dmxInput->devs[i]->process_input(dmxInput->devs[i]->private);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Xephyr - A kdrive X server thats runs in a host X window.
|
* Xephyr - A kdrive X server thats runs in a host X window.
|
||||||
* Authored by Matthew Allum <mallum@openedhand.com>
|
* Authored by Matthew Allum <mallum@openedhand.com>
|
||||||
*
|
*
|
||||||
* Copyright © 2004 Nokia
|
* Copyright © 2004 Nokia
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Xephyr - A kdrive X server thats runs in a host X window.
|
* Xephyr - A kdrive X server thats runs in a host X window.
|
||||||
* Authored by Matthew Allum <mallum@o-hand.com>
|
* Authored by Matthew Allum <mallum@o-hand.com>
|
||||||
*
|
*
|
||||||
* Copyright © 2004 Nokia
|
* Copyright © 2004 Nokia
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2006 Intel Corporation
|
* Copyright © 2006 Intel Corporation
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Xephyr - A kdrive X server thats runs in a host X window.
|
* Xephyr - A kdrive X server thats runs in a host X window.
|
||||||
* Authored by Matthew Allum <mallum@o-hand.com>
|
* Authored by Matthew Allum <mallum@o-hand.com>
|
||||||
*
|
*
|
||||||
* Copyright © 2004 Nokia
|
* Copyright © 2004 Nokia
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
@ -97,6 +97,7 @@ InitInput (int argc, char **argv)
|
||||||
void
|
void
|
||||||
CloseInput (void)
|
CloseInput (void)
|
||||||
{
|
{
|
||||||
|
KdCloseInput();
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DDXBEFORERESET
|
#ifdef DDXBEFORERESET
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Xephyr - A kdrive X server thats runs in a host X window.
|
* Xephyr - A kdrive X server thats runs in a host X window.
|
||||||
* Authored by Matthew Allum <mallum@o-hand.com>
|
* Authored by Matthew Allum <mallum@o-hand.com>
|
||||||
*
|
*
|
||||||
* Copyright © 2004 Nokia
|
* Copyright © 2004 Nokia
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Xephyr - A kdrive X server thats runs in a host X window.
|
* Xephyr - A kdrive X server thats runs in a host X window.
|
||||||
* Authored by Matthew Allum <mallum@o-hand.com>
|
* Authored by Matthew Allum <mallum@o-hand.com>
|
||||||
*
|
*
|
||||||
* Copyright © 2004 Nokia
|
* Copyright © 2004 Nokia
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Xephyr - A kdrive X server thats runs in a host X window.
|
* Xephyr - A kdrive X server thats runs in a host X window.
|
||||||
* Authored by Matthew Allum <mallum@o-hand.com>
|
* Authored by Matthew Allum <mallum@o-hand.com>
|
||||||
*
|
*
|
||||||
* Copyright © 2004 Nokia
|
* Copyright © 2004 Nokia
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -61,6 +61,7 @@ InitInput (int argc, char **argv)
|
||||||
void
|
void
|
||||||
CloseInput (void)
|
CloseInput (void)
|
||||||
{
|
{
|
||||||
|
KdCloseInput ();
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DDXBEFORERESET
|
#ifdef DDXBEFORERESET
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
@ -47,6 +47,7 @@ InitInput (int argc, char **argv)
|
||||||
void
|
void
|
||||||
CloseInput (void)
|
CloseInput (void)
|
||||||
{
|
{
|
||||||
|
KdCloseInput ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
* XKB integration © 2006 Nokia Corporation, author: Tomas Frydrych <tf@o-hand.com>
|
* XKB integration © 2006 Nokia Corporation, author: Tomas Frydrych <tf@o-hand.com>
|
||||||
*
|
*
|
||||||
* LinuxKeyboardRead() XKB code based on xf86KbdLnx.c:
|
* LinuxKeyboardRead() XKB code based on xf86KbdLnx.c:
|
||||||
* Copyright © 1990,91 by Thomas Roell, Dinkelscherben, Germany.
|
* Copyright © 1990,91 by Thomas Roell, Dinkelscherben, Germany.
|
||||||
* Copyright © 1994-2001 by The XFree86 Project, Inc.
|
* Copyright © 1994-2001 by The XFree86 Project, Inc.
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2001 Keith Packard
|
* Copyright © 2001 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -4,11 +4,11 @@
|
||||||
* Derived from ts.c by Keith Packard
|
* Derived from ts.c by Keith Packard
|
||||||
* Derived from ps2.c by Jim Gettys
|
* Derived from ps2.c by Jim Gettys
|
||||||
*
|
*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
* Copyright © 2000 Compaq Computer Corporation
|
* Copyright © 2000 Compaq Computer Corporation
|
||||||
* Copyright © 2002 MontaVista Software Inc.
|
* Copyright © 2002 MontaVista Software Inc.
|
||||||
* Copyright © 2005 OpenedHand Ltd.
|
* Copyright © 2005 OpenedHand Ltd.
|
||||||
* Copyright © 2006 Nokia Corporation
|
* Copyright © 2006 Nokia Corporation
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
@ -500,6 +500,8 @@ KdScreenInfoDispose (KdScreenInfo *si);
|
||||||
/* kinput.c */
|
/* kinput.c */
|
||||||
void
|
void
|
||||||
KdInitInput(void);
|
KdInitInput(void);
|
||||||
|
void
|
||||||
|
KdCloseInput(void);
|
||||||
|
|
||||||
void
|
void
|
||||||
KdAddPointerDriver(KdPointerDriver *);
|
KdAddPointerDriver(KdPointerDriver *);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
* Copyright © 2006 Nokia Corporation
|
* Copyright © 2006 Nokia Corporation
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
@ -1305,6 +1305,12 @@ KdInitInput (void)
|
||||||
mieqInit();
|
mieqInit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
KdCloseInput (void)
|
||||||
|
{
|
||||||
|
mieqFini();
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Middle button emulation state machine
|
* Middle button emulation state machine
|
||||||
*
|
*
|
||||||
|
@ -2159,7 +2165,6 @@ void
|
||||||
ProcessInputEvents (void)
|
ProcessInputEvents (void)
|
||||||
{
|
{
|
||||||
mieqProcessInputEvents();
|
mieqProcessInputEvents();
|
||||||
miPointerUpdateSprite(inputInfo.pointer);
|
|
||||||
if (kdSwitchPending)
|
if (kdSwitchPending)
|
||||||
KdProcessSwitch ();
|
KdProcessSwitch ();
|
||||||
KdCheckLock ();
|
KdCheckLock ();
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 1999 Keith Packard
|
* Copyright © 1999 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -148,4 +148,5 @@ InitInput(int argc, char *argv[])
|
||||||
void
|
void
|
||||||
CloseInput (void)
|
CloseInput (void)
|
||||||
{
|
{
|
||||||
|
mieqFini();
|
||||||
}
|
}
|
||||||
|
|
|
@ -825,6 +825,7 @@ void
|
||||||
CloseInput (void)
|
CloseInput (void)
|
||||||
{
|
{
|
||||||
config_fini();
|
config_fini();
|
||||||
|
mieqFini();
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -13,6 +13,7 @@
|
||||||
#define XKBSRV_NEED_FILE_FUNCS
|
#define XKBSRV_NEED_FILE_FUNCS
|
||||||
#include <xkbsrv.h>
|
#include <xkbsrv.h>
|
||||||
|
|
||||||
|
#include "dixgrabs.h"
|
||||||
#include "os.h"
|
#include "os.h"
|
||||||
#include "xf86.h"
|
#include "xf86.h"
|
||||||
|
|
||||||
|
@ -29,6 +30,20 @@ XkbDDXPrivate(DeviceIntPtr dev,KeyCode key,XkbAction *act)
|
||||||
xf86ProcessActionEvent(ACTION_PREV_MODE, NULL);
|
xf86ProcessActionEvent(ACTION_PREV_MODE, NULL);
|
||||||
else if (strcasecmp(msgbuf, "+vmode")==0)
|
else if (strcasecmp(msgbuf, "+vmode")==0)
|
||||||
xf86ProcessActionEvent(ACTION_NEXT_MODE, NULL);
|
xf86ProcessActionEvent(ACTION_NEXT_MODE, NULL);
|
||||||
|
else if (strcasecmp(msgbuf, "prgrbs")==0) {
|
||||||
|
DeviceIntPtr tmp;
|
||||||
|
xf86Msg(X_INFO, "Printing all currently active device grabs:\n");
|
||||||
|
for (tmp = inputInfo.devices; tmp; tmp = tmp->next)
|
||||||
|
if (tmp->deviceGrab.grab)
|
||||||
|
PrintDeviceGrabInfo(tmp);
|
||||||
|
xf86Msg(X_INFO, "End list of active device grabs\n");
|
||||||
|
}
|
||||||
|
else if (strcasecmp(msgbuf, "ungrab")==0)
|
||||||
|
UngrabAllDevices(FALSE);
|
||||||
|
else if (strcasecmp(msgbuf, "clsgrb")==0)
|
||||||
|
UngrabAllDevices(TRUE);
|
||||||
|
else if (strcasecmp(msgbuf, "prwins")==0)
|
||||||
|
PrintWindowTree();
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -1185,6 +1185,7 @@ void
|
||||||
DRI2CloseScreen(ScreenPtr pScreen)
|
DRI2CloseScreen(ScreenPtr pScreen)
|
||||||
{
|
{
|
||||||
DRI2ScreenPtr ds = DRI2GetScreen(pScreen);
|
DRI2ScreenPtr ds = DRI2GetScreen(pScreen);
|
||||||
|
pScreen->ConfigNotify = ds->ConfigNotify;
|
||||||
|
|
||||||
free(ds->driverNames);
|
free(ds->driverNames);
|
||||||
free(ds);
|
free(ds);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2006 Intel Corporation
|
* Copyright © 2006 Intel Corporation
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2006 Intel Corporation
|
* Copyright © 2006 Intel Corporation
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -152,7 +152,7 @@ xf86CVTMode(int HDisplay, int VDisplay, float VRefresh, Bool Reduced,
|
||||||
|
|
||||||
if (!Reduced) { /* simplified GTF calculation */
|
if (!Reduced) { /* simplified GTF calculation */
|
||||||
|
|
||||||
/* 4) Minimum time of vertical sync + back porch interval (µs)
|
/* 4) Minimum time of vertical sync + back porch interval (µs)
|
||||||
* default 550.0 */
|
* default 550.0 */
|
||||||
#define CVT_MIN_VSYNC_BP 550.0
|
#define CVT_MIN_VSYNC_BP 550.0
|
||||||
|
|
||||||
|
@ -223,7 +223,7 @@ xf86CVTMode(int HDisplay, int VDisplay, float VRefresh, Bool Reduced,
|
||||||
Mode->VSyncEnd = Mode->VSyncStart + VSync;
|
Mode->VSyncEnd = Mode->VSyncStart + VSync;
|
||||||
|
|
||||||
} else { /* Reduced blanking */
|
} else { /* Reduced blanking */
|
||||||
/* Minimum vertical blanking interval time (µs) - default 460 */
|
/* Minimum vertical blanking interval time (µs) - default 460 */
|
||||||
#define CVT_RB_MIN_VBLANK 460.0
|
#define CVT_RB_MIN_VBLANK 460.0
|
||||||
|
|
||||||
/* Fixed number of clocks for horizontal sync */
|
/* Fixed number of clocks for horizontal sync */
|
||||||
|
|
|
@ -3,8 +3,8 @@
|
||||||
*
|
*
|
||||||
* This version is for Solaris.
|
* This version is for Solaris.
|
||||||
*
|
*
|
||||||
* Copyright © 2000 VA Linux Systems, Inc.
|
* Copyright © 2000 VA Linux Systems, Inc.
|
||||||
* Copyright © 2001 The XFree86 Project, Inc.
|
* Copyright © 2001 The XFree86 Project, Inc.
|
||||||
*/
|
*/
|
||||||
/* Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
|
/* Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
|
||||||
*
|
*
|
||||||
|
|
|
@ -108,6 +108,7 @@ InitInput(int argc, char *argv[])
|
||||||
void
|
void
|
||||||
CloseInput(void)
|
CloseInput(void)
|
||||||
{
|
{
|
||||||
|
mieqFini();
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -505,6 +505,10 @@ void InitInput( int argc, char **argv )
|
||||||
QuartzInitInput(argc, argv);
|
QuartzInitInput(argc, argv);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void CloseInput(void)
|
||||||
|
{
|
||||||
|
DarwinEQFini();
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* DarwinAdjustScreenOrigins
|
* DarwinAdjustScreenOrigins
|
||||||
|
|
|
@ -371,6 +371,10 @@ Bool DarwinEQInit(void) {
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Bool DarwinEQFini(void) {
|
||||||
|
mieqFini();
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* ProcessInputEvents
|
* ProcessInputEvents
|
||||||
* Read and process events from the event queue until it is empty.
|
* Read and process events from the event queue until it is empty.
|
||||||
|
|
|
@ -32,6 +32,7 @@
|
||||||
#define XQUARTZ_VALUATOR_LIMIT (1 << 16)
|
#define XQUARTZ_VALUATOR_LIMIT (1 << 16)
|
||||||
|
|
||||||
Bool DarwinEQInit(void);
|
Bool DarwinEQInit(void);
|
||||||
|
Bool DarwinEQFini(void);
|
||||||
void DarwinEQEnqueue(const xEventPtr e);
|
void DarwinEQEnqueue(const xEventPtr e);
|
||||||
void DarwinEQPointerPost(DeviceIntPtr pDev, xEventPtr e);
|
void DarwinEQPointerPost(DeviceIntPtr pDev, xEventPtr e);
|
||||||
void DarwinEQSwitchScreen(ScreenPtr pScreen, Bool fromDIX);
|
void DarwinEQSwitchScreen(ScreenPtr pScreen, Bool fromDIX);
|
||||||
|
|
|
@ -149,8 +149,3 @@ DeleteInputDeviceRequest(DeviceIntPtr dev)
|
||||||
DEBUG_LOG("DeleteInputDeviceRequest(%p)\n", dev);
|
DEBUG_LOG("DeleteInputDeviceRequest(%p)\n", dev);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
CloseInput (void)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
|
@ -156,4 +156,5 @@ InitInput (int argc, char *argv[])
|
||||||
void
|
void
|
||||||
CloseInput (void)
|
CloseInput (void)
|
||||||
{
|
{
|
||||||
|
mieqFini ();
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,6 +28,9 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
|
||||||
struct _GrabParameters;
|
struct _GrabParameters;
|
||||||
|
|
||||||
|
extern void PrintDeviceGrabInfo(DeviceIntPtr dev);
|
||||||
|
extern void UngrabAllDevices(Bool kill_client);
|
||||||
|
|
||||||
extern GrabPtr CreateGrab(
|
extern GrabPtr CreateGrab(
|
||||||
int /* client */,
|
int /* client */,
|
||||||
DeviceIntPtr /* device */,
|
DeviceIntPtr /* device */,
|
||||||
|
|
|
@ -62,10 +62,11 @@ SOFTWARE.
|
||||||
#define DEVICE_OFF 2
|
#define DEVICE_OFF 2
|
||||||
#define DEVICE_CLOSE 3
|
#define DEVICE_CLOSE 3
|
||||||
|
|
||||||
#define POINTER_RELATIVE (1 << 1)
|
#define POINTER_RELATIVE (1 << 1)
|
||||||
#define POINTER_ABSOLUTE (1 << 2)
|
#define POINTER_ABSOLUTE (1 << 2)
|
||||||
#define POINTER_ACCELERATE (1 << 3)
|
#define POINTER_ACCELERATE (1 << 3)
|
||||||
#define POINTER_SCREEN (1 << 4) /* Data in screen coordinates */
|
#define POINTER_SCREEN (1 << 4) /* Data in screen coordinates */
|
||||||
|
#define POINTER_NORAW (1 << 5) /* Don't generate RawEvents */
|
||||||
|
|
||||||
/*int constants for pointer acceleration schemes*/
|
/*int constants for pointer acceleration schemes*/
|
||||||
#define PtrAccelNoOp 0
|
#define PtrAccelNoOp 0
|
||||||
|
|
|
@ -267,4 +267,6 @@ extern _X_EXPORT void EnableMapUnmapEvents(
|
||||||
WindowPtr /* pWin */ );
|
WindowPtr /* pWin */ );
|
||||||
|
|
||||||
extern _X_EXPORT void SetRootClip(ScreenPtr pScreen, Bool enable);
|
extern _X_EXPORT void SetRootClip(ScreenPtr pScreen, Bool enable);
|
||||||
|
extern _X_EXPORT void PrintWindowTree(void);
|
||||||
|
|
||||||
#endif /* WINDOW_H */
|
#endif /* WINDOW_H */
|
||||||
|
|
|
@ -683,7 +683,7 @@ miPointerMove (DeviceIntPtr pDev, ScreenPtr pScreen, int x, int y)
|
||||||
|
|
||||||
valuator_mask_set_range(&mask, 0, 2, valuators);
|
valuator_mask_set_range(&mask, 0, 2, valuators);
|
||||||
nevents = GetPointerEvents(events, pDev, MotionNotify, 0,
|
nevents = GetPointerEvents(events, pDev, MotionNotify, 0,
|
||||||
POINTER_SCREEN | POINTER_ABSOLUTE, &mask);
|
POINTER_SCREEN | POINTER_ABSOLUTE | POINTER_NORAW, &mask);
|
||||||
|
|
||||||
OsBlockSignals();
|
OsBlockSignals();
|
||||||
#ifdef XQUARTZ
|
#ifdef XQUARTZ
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright © 2000 Keith Packard
|
* Copyright © 2000 Keith Packard
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||||
* documentation for any purpose is hereby granted without fee, provided that
|
* documentation for any purpose is hereby granted without fee, provided that
|
||||||
|
|
|
@ -40,5 +40,6 @@ libxservertest_la_LIBADD = \
|
||||||
$(top_builddir)/mi/libmi.la \
|
$(top_builddir)/mi/libmi.la \
|
||||||
$(top_builddir)/os/libos.la \
|
$(top_builddir)/os/libos.la \
|
||||||
@XORG_LIBS@
|
@XORG_LIBS@
|
||||||
|
libxservertest_la_DEPENDENCIES = $(libxservertest_la_LIBADD)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
|
@ -70,6 +70,8 @@ static void test_values_XIRawEvent(RawDeviceEvent *in, xXIRawEvent *out,
|
||||||
|
|
||||||
for (i = 0; out->valuators_len && i < sizeof(in->valuators.mask) * 8; i++)
|
for (i = 0; out->valuators_len && i < sizeof(in->valuators.mask) * 8; i++)
|
||||||
{
|
{
|
||||||
|
if (i >= MAX_VALUATORS)
|
||||||
|
assert (!XIMaskIsSet(in->valuators.mask, i));
|
||||||
assert (XIMaskIsSet(in->valuators.mask, i) == XIMaskIsSet(ptr, i));
|
assert (XIMaskIsSet(in->valuators.mask, i) == XIMaskIsSet(ptr, i));
|
||||||
if (XIMaskIsSet(in->valuators.mask, i))
|
if (XIMaskIsSet(in->valuators.mask, i))
|
||||||
bits_set++;
|
bits_set++;
|
||||||
|
@ -238,7 +240,7 @@ static void test_convert_XIRawEvent(void)
|
||||||
test_XIRawEvent(&in);
|
test_XIRawEvent(&in);
|
||||||
|
|
||||||
printf("Testing valuator masks\n");
|
printf("Testing valuator masks\n");
|
||||||
for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
|
for (i = 0; i < MAX_VALUATORS; i++)
|
||||||
{
|
{
|
||||||
XISetMask(in.valuators.mask, i);
|
XISetMask(in.valuators.mask, i);
|
||||||
test_XIRawEvent(&in);
|
test_XIRawEvent(&in);
|
||||||
|
@ -257,7 +259,7 @@ static void test_convert_XIRawEvent(void)
|
||||||
XIClearMask(in.valuators.mask, i);
|
XIClearMask(in.valuators.mask, i);
|
||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
|
for (i = 0; i < MAX_VALUATORS; i++)
|
||||||
{
|
{
|
||||||
XISetMask(in.valuators.mask, i);
|
XISetMask(in.valuators.mask, i);
|
||||||
test_XIRawEvent(&in);
|
test_XIRawEvent(&in);
|
||||||
|
@ -354,7 +356,7 @@ static void test_values_XIDeviceEvent(DeviceEvent *in, xXIDeviceEvent *out,
|
||||||
|
|
||||||
|
|
||||||
valuators = 0;
|
valuators = 0;
|
||||||
for (i = 0; i < sizeof(in->valuators.mask) * 8; i++)
|
for (i = 0; i < MAX_VALUATORS; i++)
|
||||||
if (XIMaskIsSet(in->valuators.mask, i))
|
if (XIMaskIsSet(in->valuators.mask, i))
|
||||||
valuators++;
|
valuators++;
|
||||||
|
|
||||||
|
@ -365,7 +367,9 @@ static void test_values_XIDeviceEvent(DeviceEvent *in, xXIDeviceEvent *out,
|
||||||
for (i = 0; i < sizeof(in->valuators.mask) * 8 ||
|
for (i = 0; i < sizeof(in->valuators.mask) * 8 ||
|
||||||
i < (out->valuators_len * 4) * 8; i++)
|
i < (out->valuators_len * 4) * 8; i++)
|
||||||
{
|
{
|
||||||
if (i > sizeof(in->valuators.mask) * 8)
|
if (i >= MAX_VALUATORS)
|
||||||
|
assert(!XIMaskIsSet(in->valuators.mask, i) && !XIMaskIsSet(ptr, i));
|
||||||
|
else if (i > sizeof(in->valuators.mask) * 8)
|
||||||
assert(!XIMaskIsSet(ptr, i));
|
assert(!XIMaskIsSet(ptr, i));
|
||||||
else if (i > out->valuators_len * 4 * 8)
|
else if (i > out->valuators_len * 4 * 8)
|
||||||
assert(!XIMaskIsSet(in->valuators.mask, i));
|
assert(!XIMaskIsSet(in->valuators.mask, i));
|
||||||
|
@ -610,14 +614,14 @@ static void test_convert_XIDeviceEvent(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("Testing valuator masks\n");
|
printf("Testing valuator masks\n");
|
||||||
for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
|
for (i = 0; i < MAX_VALUATORS; i++)
|
||||||
{
|
{
|
||||||
XISetMask(in.valuators.mask, i);
|
XISetMask(in.valuators.mask, i);
|
||||||
test_XIDeviceEvent(&in);
|
test_XIDeviceEvent(&in);
|
||||||
XIClearMask(in.valuators.mask, i);
|
XIClearMask(in.valuators.mask, i);
|
||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
|
for (i = 0; i < MAX_VALUATORS; i++)
|
||||||
{
|
{
|
||||||
XISetMask(in.valuators.mask, i);
|
XISetMask(in.valuators.mask, i);
|
||||||
|
|
||||||
|
@ -627,7 +631,7 @@ static void test_convert_XIDeviceEvent(void)
|
||||||
XIClearMask(in.valuators.mask, i);
|
XIClearMask(in.valuators.mask, i);
|
||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
|
for (i = 0; i < MAX_VALUATORS; i++)
|
||||||
{
|
{
|
||||||
XISetMask(in.valuators.mask, i);
|
XISetMask(in.valuators.mask, i);
|
||||||
test_XIDeviceEvent(&in);
|
test_XIDeviceEvent(&in);
|
||||||
|
|
Loading…
Reference in New Issue