xserver: Branch 'master' - 3 commits

Peter Hutterer whot at kemper.freedesktop.org
Fri Sep 25 19:37:14 PDT 2009


 Xi/exevents.c            |    2 +-
 configure.ac             |   26 +++++++++++++++++---------
 hw/dmx/input/dmxevents.c |    8 ++++----
 3 files changed, 22 insertions(+), 14 deletions(-)

New commits:
commit e7c2598f565e8252dd66ee3e6212b310856476cb
Author: Peter Hutterer <peter.hutterer at who-t.net>
Date:   Fri Sep 25 14:53:33 2009 +1000

    dmx: core events are always in screen coordinates when passed to GPE.
    
    This fixes input in dmx, the pointer appears at the right positions to the
    clients now.
    
    Also mark the spot where we pass in the button state as valuator to GPE
    with a FIXME. (??)
    
    Tested-by: Kevin Martin
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

diff --git a/hw/dmx/input/dmxevents.c b/hw/dmx/input/dmxevents.c
index 5c3d792..70737b4 100644
--- a/hw/dmx/input/dmxevents.c
+++ b/hw/dmx/input/dmxevents.c
@@ -183,7 +183,7 @@ static void enqueueMotion(DevicePtr pDev, int x, int y)
 
     GetEventList(&events);
     nevents = GetPointerEvents(events, p, MotionNotify, detail,
-                               POINTER_ABSOLUTE, 0, 2, valuators);
+                               POINTER_ABSOLUTE | POINTER_SCREEN, 0, 2, valuators);
     for (i = 0; i < nevents; i++)
        mieqEnqueue(p, (InternalEvent*)(events + i)->event);
     return;
@@ -688,7 +688,7 @@ void dmxEnqueue(DevicePtr pDev, int type, int detail, KeySym keySym,
         detail = dmxGetButtonMapping(dmxLocal, detail);
         GetEventList(&events);
         nevents = GetPointerEvents(events, p, type, detail,
-                                   POINTER_ABSOLUTE,
+                                   POINTER_ABSOLUTE | POINTER_SCREEN,
                                    0,   /* first_valuator = 0 */
                                    0,   /* num_valuators = 0 */
                                    valuators);
@@ -700,9 +700,9 @@ void dmxEnqueue(DevicePtr pDev, int type, int detail, KeySym keySym,
         GetEventList(&events);
         valuators[0] = e->xmotion.x;
         valuators[1] = e->xmotion.y;
-        valuators[2] = e->xmotion.state;
+        valuators[2] = e->xmotion.state; /* FIXME: WTF?? */
         nevents = GetPointerEvents(events, p, type, detail, 
-                                   POINTER_ABSOLUTE, 0, 3, valuators);
+                                   POINTER_ABSOLUTE | POINTER_SCREEN, 0, 3, valuators);
         for (i = 0; i < nevents; i++)
             mieqEnqueue(p, (InternalEvent*)(events + i)->event);
         return;
commit 43a2eb794f19a2ba56d653f465fc5f6b2ff0d3d3
Author: Peter Hutterer <peter.hutterer at who-t.net>
Date:   Wed Sep 23 21:49:11 2009 +1000

    configure: Unify all library defines that require a specific version.
    
    This patch moves all libraries that require a specific version into a single
    location instead or duplicating them across the configure.ac file.
    Libraries that do not require specific versions are left where they are.
    
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

diff --git a/configure.ac b/configure.ac
index 7acdbee..82d86db 100644
--- a/configure.ac
+++ b/configure.ac
@@ -738,7 +738,15 @@ dnl Core modules for most extensions, et al.
 REQUIRED_MODULES="[randrproto >= 1.2.99.3] [renderproto >= 0.11] [fixesproto >= 4.1] [damageproto >= 1.1] [xcmiscproto >= 1.2.0] [xextproto >= 7.0.99.3] [xproto >= 7.0.13] [xtrans >= 1.2.2] [bigreqsproto >= 1.1.0] fontsproto [inputproto >= 1.9.99.902] [kbproto >= 1.0.3]"
 REQUIRED_LIBS="xfont xau [pixman-1 >= 0.15.20]"
 
+dnl List of libraries that require a specific version
+LIBAPPLEWM="applewm >= 1.4"
+LIBDRI="dri >= 7.1.0"
+LIBDRM="libdrm >= 2.3.0"
+LIBGL="gl >= 7.1.0"
 LIBXEXT="xext >= 1.0.99.4"
+LIBXI="xi >= 1.2.99.1"
+LIBPCIACCESS="pciaccess >= 0.8.0"
+LIBGLIB="glib-2.0 >= 2.16"
 
 dnl HAVE_DBUS is true if we actually have the D-Bus library, whereas
 dnl CONFIG_DBUS_API is true if we want to enable the D-Bus config
@@ -903,7 +911,7 @@ fi
 
 if test "x$GLX" = xyes; then
 	PKG_CHECK_MODULES([XLIB], [x11])
-	PKG_CHECK_MODULES([GL], $GLPROTO [gl >= 7.1.0])
+	PKG_CHECK_MODULES([GL], $GLPROTO $LIBGL)
 	AC_SUBST(XLIB_CFLAGS)
 	AC_DEFINE(GLXEXT, 1, [Build GLX extension])
 	GLX_LIBS='$(top_builddir)/glx/libglx.la'
@@ -930,7 +938,7 @@ AM_CONDITIONAL(DRI, test "x$DRI" = xyes)
 if test "x$DRI" = xyes; then
 	AC_DEFINE(XF86DRI, 1, [Build DRI extension])
 	PKG_CHECK_MODULES([DRIPROTO], [$DRIPROTO])
-	PKG_CHECK_MODULES([DRI], $GLPROTO [dri >= 7.1.0])
+	PKG_CHECK_MODULES([DRI], $GLPROTO $LIBDRI)
 	AC_SUBST(DRIPROTO_CFLAGS)
 fi
 
@@ -948,7 +956,7 @@ esac
 AM_CONDITIONAL(DRI2, test "x$DRI2" = xyes)
 
 if test "x$DRI" = xyes || test "x$DRI2" = xyes; then
-	PKG_CHECK_MODULES([LIBDRM], [libdrm >= 2.3.0])
+	PKG_CHECK_MODULES([LIBDRM], $LIBDRM)
 	AC_SUBST(LIBDRM_CFLAGS)
 	AC_SUBST(LIBDRM_LIBS)
 fi
@@ -1195,7 +1203,7 @@ AM_CONDITIONAL(DEBUG, [test "x$DEBUGGING" = xyes])
 
 # If unittests aren't explicitly disabled, check for required support
 if test "x$UNITTESTS" != xno ; then
-       PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.16],
+       PKG_CHECK_MODULES([GLIB], $LIBGLIB,
                          [HAVE_GLIB=yes], [HAVE_GLIB=no])
 
        # Check if linker supports -wrap, passed via compiler flags
@@ -1444,7 +1452,7 @@ if test "x$XORG" = xyes; then
 	AC_SUBST([symbol_visibility])
 	dnl ===================================================================
 
-	PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.8.0])
+	PKG_CHECK_MODULES([PCIACCESS], $LIBPCIACCESS)
 	SAVE_LIBS=$LIBS
 	SAVE_CFLAGS=$CFLAGS
 	CFLAGS=$PCIACCESS_CFLAGS
@@ -1750,7 +1758,7 @@ if test "x$XQUARTZ" = xyes; then
 
 	CFLAGS="${CFLAGS} -DROOTLESS_WORKAROUND -DROOTLESS_SAFEALPHA -DNO_ALLOCA"
 
-	PKG_CHECK_MODULES(XPBPROXY, $APPLEWMPROTO [applewm >= 1.4] xfixes x11)
+	PKG_CHECK_MODULES(XPBPROXY, $APPLEWMPROTO $LIBAPPLEWM xfixes x11)
 
         if test "x$XQUARTZ_SPARKLE" = xyes ; then
                 AC_DEFINE(XQUARTZ_SPARKLE,1,[Support application updating through sparkle.])
@@ -1779,7 +1787,7 @@ AM_CONDITIONAL(STANDALONE_XPBPROXY, [test "x$STANDALONE_XPBPROXY" = xyes])
 dnl DMX DDX
 
 PKG_CHECK_MODULES([DMXMODULES],
-    [xmuu $LIBXEXT x11 xrender xfixes xfont xi >= 1.2.99.1 $DMXPROTO xau $XDMCP_MODULES],
+    [xmuu $LIBXEXT x11 xrender xfixes xfont $LIBXI $DMXPROTO xau $XDMCP_MODULES],
     [have_dmx=yes], [have_dmx=no])
 AC_MSG_CHECKING([whether to build Xdmx DDX])
 if test "x$DMX" = xauto; then
@@ -1818,7 +1826,7 @@ dnl Linux sources in DMX require <linux/keyboard.h>
 	AC_SUBST(DMXEXAMPLES_DEP_LIBS)
 	PKG_CHECK_MODULES([DMXXMUEXAMPLES_DEP], [dmx xmu $LIBXEXT x11])
 	AC_SUBST(DMXXMUEXAMPLES_DEP_LIBS)
-	PKG_CHECK_MODULES([DMXXIEXAMPLES_DEP], [dmx xi $LIBXEXT x11])
+	PKG_CHECK_MODULES([DMXXIEXAMPLES_DEP], [dmx $LIBXI $LIBXEXT x11])
 	AC_SUBST(DMXXIEXAMPLES_DEP_LIBS)
 	PKG_CHECK_MODULES([XTSTEXAMPLES_DEP], [xtst $LIBXEXT x11])
 	AC_SUBST(XTSTEXAMPLES_DEP_LIBS)
@@ -1898,7 +1906,7 @@ if test "$KDRIVE" = yes; then
         XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS xv"
     fi
     if test "x$DRI" = xyes && test "x$GLX" = xyes; then
-        XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS gl libdrm"
+        XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS $LIBGL libdrm"
     fi
 
     PKG_CHECK_MODULES(XEPHYR, $XEPHYR_REQUIRED_LIBS, [xephyr="yes"], [xephyr="no"])
commit 9bd08c690fc687c4d69bb70536f3079a9184476d
Author: Peter Hutterer <peter.hutterer at who-t.net>
Date:   Thu Sep 24 14:07:26 2009 +1000

    Xi: update axisVals with the right subpixel data.
    
    Subpixel data in data_frac is stored as FP32.32, hence we need to get that
    down again before adding it to the current value.
    
    Reported-by: Thomas Jaeger
    Tested-by: Thomas Jaeger
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

diff --git a/Xi/exevents.c b/Xi/exevents.c
index b0e0ede..2673552 100644
--- a/Xi/exevents.c
+++ b/Xi/exevents.c
@@ -805,7 +805,7 @@ UpdateDeviceState(DeviceIntPtr device, DeviceEvent* event)
         {
             /* XXX: Relative/Absolute mode */
             v->axisVal[i] = event->valuators.data[i];
-            v->axisVal[i] += event->valuators.data_frac[i];
+            v->axisVal[i] += (event->valuators.data_frac[i] * 1.0f / (1 << 16) / (1 << 16));
         }
     }
 


More information about the xorg-commit mailing list