Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/xserver

This commit is contained in:
Ian Romanick 2006-07-21 13:55:37 -07:00
commit 22db3fdb54
14 changed files with 28 additions and 139 deletions

View File

@ -59,7 +59,9 @@ of the copyright holder.
#define NoSuchEvent 0x80000000
#ifdef XKB
extern Bool noXkbExtension;
#endif
extern int xeviegrabState;
static int ProcDispatch (register ClientPtr client), SProcDispatch (register ClientPtr client);
@ -201,12 +203,14 @@ int ProcStart (register ClientPtr client)
return BadAlloc;
} else
return BadAccess;
#ifdef XKB
if (!noXkbExtension) {
if (!XevieStart()) {
DeleteCallback(&ClientStateCallback,XevieClientStateCallback,NULL);
return BadAlloc;
}
}
#endif
xevieModifiersOn = FALSE;
@ -255,19 +259,23 @@ int ProcSend (register ClientPtr client)
case KeyPress:
case KeyRelease:
xevieKBEventSent = 1;
if(noXkbExtension)
CoreProcessKeyboardEvent (xE, xeviekb, 1);
else
#ifdef XKB
if(!noXkbExtension)
doSendEvent(xE, inputInfo.keyboard);
else
#endif
CoreProcessKeyboardEvent (xE, xeviekb, 1);
break;
case ButtonPress:
case ButtonRelease:
case MotionNotify:
xevieEventSent = 1;
if(noXkbExtension)
CoreProcessPointerEvent(xE, xeviemouse, 1);
else
#ifdef XKB
if(!noXkbExtension)
doSendEvent(xE, inputInfo.pointer);
else
#endif
CoreProcessPointerEvent(xE, xeviemouse, 1);
break;
default:
break;
@ -464,6 +472,7 @@ XevieKbdProcessInputProc(xEvent *xE, DeviceIntPtr dev, int count)
xE->u.keyButtonPointer.state = keyc->state | inputInfo.pointer->button->state;
/* fix bug: sequence lost in Xlib */
xE->u.u.sequenceNumber = clients[xevieClientIndex]->sequence;
#ifdef XKB
/* fix for bug5092586 */
if(!noXkbExtension) {
switch(xE->u.u.type) {
@ -471,6 +480,7 @@ XevieKbdProcessInputProc(xEvent *xE, DeviceIntPtr dev, int count)
case KeyRelease: *kptr &= ~bit; break;
}
}
#endif
keycq[keycqHead].time = xE->u.keyButtonPointer.time;
memcpy(keycq[keycqHead].keyc, keyc, sizeof(KeyClassRec) - sizeof(KeyClassPtr));
memcpy(keycq[keycqHead].keyc->xkbInfo, keyc->xkbInfo, sizeof(XkbSrvInfoRec));
@ -525,6 +535,7 @@ XevieEnd(int clientIndex)
{
if (!clientIndex || clientIndex == xevieClientIndex) {
#ifdef XKB
if(!noXkbExtension) {
XevieRemove(inputInfo.keyboard,NULL);
@ -540,6 +551,7 @@ XevieEnd(int clientIndex)
inputInfo.pointer->public.realInputProc = CoreProcessPointerEvent;
XkbSetExtension(inputInfo.pointer,ProcessPointerEvent);
}
#endif
xevieFlag = 0;
xevieClientIndex = 0;

View File

@ -469,7 +469,7 @@ AC_MSG_RESULT([$SETUID])
AM_CONDITIONAL(INSTALL_SETUID, [test "x$SETUID" = "xyes"])
dnl Issue an error if xtrans.m4 was not found and XTRANS_CONNECTION_FLAGS macro
dnl was not expanded, since libX11 with no transport types is rather useless.
dnl was not expanded, since xorg-server with no transport types is rather useless.
dnl
dnl If you're seeing an error here, be sure you installed the lib/xtrans module
dnl first and if it's not in the default location, that you set the ACLOCAL

View File

@ -606,7 +606,9 @@ exaDriverInit (ScreenPtr pScreen,
}
#endif
#ifdef COMPOSITE
miDisableCompositeWrapper(pScreen);
#endif
/*
* Hookup offscreen pixmaps

View File

@ -1046,14 +1046,3 @@ void ddxUseMsg(void)
ErrorF(" Ctrl-Alt-q Quit (core devices only)\n");
ErrorF(" Ctrl-Alt-F* Switch to VC (local only)\n");
}
#ifdef DDXTIME
/** Return wall-clock time in milliseconds. */
CARD32 GetTimeInMillis(void)
{
struct timeval tp;
gettimeofday(&tp, 0);
return tp.tv_sec * 1000 + tp.tv_usec / 1000;
}
#endif

View File

@ -1814,7 +1814,7 @@ KdXVCopyPackedData(KdScreenInfo *screen, CARD8 *src, CARD8 *dst, int randr,
src = src + top * srcDown + left * srcRight;
w >>= 1;
srcRight >>= 1;
/* srcRight >>= 1; */
srcNext = srcRight >> 1;
while (h--) {
CARD16 *s = (CARD16 *)src;

View File

@ -450,17 +450,6 @@ ddxProcessArgument(int argc, char *argv[], int i)
return 0;
}
#ifdef DDXTIME /* from ServerOSDefines */
CARD32
GetTimeInMillis()
{
struct timeval tp;
X_GETTIMEOFDAY(&tp);
return(tp.tv_sec * 1000) + (tp.tv_usec / 1000);
}
#endif
static ColormapPtr InstalledMaps[MAXSCREENS];
static int

View File

@ -470,32 +470,3 @@ searchdone:
}
return (Success);
}
#if defined(DDXTIME) && !defined(QNX4)
/*
* These are getting tossed in here until I can think of where
* they really belong
*/
#define HALFMONTH ((unsigned long) 1<<31)
_X_EXPORT CARD32
GetTimeInMillis()
{
struct timeval tp;
register CARD32 val;
register INT32 diff;
static CARD32 oldval = 0;
static CARD32 time = 0;
gettimeofday(&tp, 0);
val = (tp.tv_sec * 1000) + (tp.tv_usec / 1000);
if (oldval) {
diff = val - oldval;
if (diff > 0)
time += diff;
}
oldval = val;
return time;
}
#endif /* DDXTIME && !QNX4 */

View File

@ -1,51 +0,0 @@
/* $Xorg: GetTime.c,v 1.3 2000/08/17 19:53:28 cpqbld Exp $ */
/*
Copyright (c) 1993 X Consortium
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
Except as contained in this notice, the name of the X Consortium shall
not be used in advertising or otherwise to promote the sale, use or
other dealings in this Software without prior written authorization
from the X Consortium.
*/
/* $XFree86$ */
#ifdef HAVE_XNEST_CONFIG_H
#include <xnest-config.h>
#endif
#include <X11/Xos.h>
#include "os.h"
#include <time.h>
#ifdef DDXTIME
CARD32
GetTimeInMillis()
{
struct timeval tp;
X_GETTIMEOFDAY(&tp);
return(tp.tv_sec * 1000) + (tp.tv_usec / 1000);
}
#endif

View File

@ -14,7 +14,6 @@ SRCS = Args.c \
GC.c \
GCOps.c \
GCOps.h \
GetTime.c \
Handlers.c \
Handlers.h \
Init.c \

View File

@ -245,17 +245,6 @@ ddxBeforeReset(void)
}
#endif
#ifdef DDXTIME
CARD32
GetTimeInMillis(void)
{
struct timeval tp;
X_GETTIMEOFDAY(&tp);
return(tp.tv_sec * 1000) + (tp.tv_usec / 1000);
}
#endif
/* ddxInitGlobals - called by |InitGlobals| from os/util.c */
void ddxInitGlobals(void)
{

View File

@ -944,15 +944,6 @@ void ddxInitGlobals(void)
{
}
#ifdef DDXTIME /* from ServerOSDefines */
CARD32
GetTimeInMillis (void)
{
return GetTickCount ();
}
#endif /* DDXTIME */
/* See Porting Layer Definition - p. 20 */
/*
* Do any global initialization, then initialize each screen.

View File

@ -231,6 +231,9 @@
/* Disable some debugging code */
#undef NDEBUG
/* Enable some debugging code */
#undef DEBUG
/* Name of package */
#undef PACKAGE

View File

@ -22,4 +22,7 @@
/* Support tslib touchscreen abstraction library */
#undef TSLIB
/* Verbose debugging output hilarity */
#undef DEBUG
#endif /* _KDRIVE_CONFIG_H_ */

View File

@ -264,12 +264,6 @@ int SyncOn = 0;
extern int SelectWaitTime;
#endif
#ifdef DEBUG
#ifndef SPECIAL_MALLOC
#define MEMBUG
#endif
#endif
#if defined(SVR4) || defined(__linux__) || defined(CSRG_BASED)
#define HAS_SAVED_IDS_AND_SETEUID
#endif
@ -545,7 +539,6 @@ GiveUp(int sig)
errno = olderrno;
}
#ifndef DDXTIME
_X_EXPORT CARD32
GetTimeInMillis(void)
{
@ -554,7 +547,6 @@ GetTimeInMillis(void)
X_GETTIMEOFDAY(&tp);
return(tp.tv_sec * 1000) + (tp.tv_usec / 1000);
}
#endif
_X_EXPORT void
AdjustWaitForDelay (pointer waitTime, unsigned long newdelay)