xserver: Branch 'server-1.7-nominations' - 2 commits

Peter Hutterer whot at kemper.freedesktop.org
Mon Mar 8 15:46:44 PST 2010


 configure.ac |    4 +--
 dix/events.c |   63 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 2 files changed, 64 insertions(+), 3 deletions(-)

New commits:
commit 2086e4920a16248aa150114236dfb0637c20559a
Author: Peter Hutterer <peter.hutterer at who-t.net>
Date:   Tue Mar 9 09:42:42 2010 +1000

    Revert "dix: Use DeliverGrabbedEvent for implicit passive grabs (#25400)"
    
    Reported-by: Florian Mickerl <florian at mickler.org>
    "this regresses my desktop. fluxbox is not able to move the windows around
    anymore. also popup of context-menue does not work. (well sometimes it does,
    but then the fluxbox-keyboard-shortcuts do not work)"
    
    This reverts commit 351d11fd466fae731df860a6ff4cf50ad565f43f.
    
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

diff --git a/dix/events.c b/dix/events.c
index c6aa4ab..02079be 100644
--- a/dix/events.c
+++ b/dix/events.c
@@ -3462,6 +3462,7 @@ CheckPassiveGrabsOnWindow(
     {
 	DeviceIntPtr	gdev;
 	XkbSrvInfoPtr	xkbi = NULL;
+	Mask		mask = 0;
 
 	gdev= grab->modifierDevice;
         if (grab->grabtype == GRABTYPE_CORE)
@@ -3514,6 +3515,10 @@ CheckPassiveGrabsOnWindow(
 	     (grab->confineTo->realized &&
 				BorderSizeNotEmpty(device, grab->confineTo))))
 	{
+            int rc, count = 0;
+            xEvent *xE = NULL;
+            xEvent core;
+
             event->corestate &= 0x1f00;
             event->corestate |= tempGrab.modifiersDetail.exact & (~0x1f00);
             grabinfo = &device->deviceGrab;
@@ -3560,8 +3565,62 @@ CheckPassiveGrabsOnWindow(
             }
 
 
+            if (match & CORE_MATCH)
+            {
+                rc = EventToCore((InternalEvent*)event, &core);
+                if (rc != Success)
+                {
+                    if (rc != BadMatch)
+                        ErrorF("[dix] %s: core conversion failed in CPGFW "
+                                "(%d, %d).\n", device->name, event->type, rc);
+                    continue;
+                }
+                xE = &core;
+                count = 1;
+                mask = grab->eventMask;
+            } else if (match & XI2_MATCH)
+            {
+                rc = EventToXI2((InternalEvent*)event, &xE);
+                if (rc != Success)
+                {
+                    if (rc != BadMatch)
+                        ErrorF("[dix] %s: XI2 conversion failed in CPGFW "
+                                "(%d, %d).\n", device->name, event->type, rc);
+                    continue;
+                }
+                count = 1;
+
+                /* FIXME: EventToXI2 returns NULL for enter events, so
+                 * dereferencing the event is bad. Internal event types are
+                 * aligned with core events, so the else clause is valid.
+                 * long-term we should use internal events for enter/focus
+                 * as well */
+                if (xE)
+                    mask = grab->xi2mask[device->id][((xGenericEvent*)xE)->evtype/8];
+                else if (event->type == XI_Enter || event->type == XI_FocusIn)
+                    mask = grab->xi2mask[device->id][event->type/8];
+            } else
+            {
+                rc = EventToXI((InternalEvent*)event, &xE, &count);
+                if (rc != Success)
+                {
+                    if (rc != BadMatch)
+                        ErrorF("[dix] %s: XI conversion failed in CPGFW "
+                                "(%d, %d).\n", device->name, event->type, rc);
+                    continue;
+                }
+                mask = grab->eventMask;
+            }
+
 	    (*grabinfo->ActivateGrab)(device, grab, currentTime, TRUE);
-            DeliverGrabbedEvent((InternalEvent*)event, device, FALSE);
+
+            if (xE)
+            {
+                FixUpEventFromWindow(device, xE, grab->window, None, TRUE);
+
+                TryClientEvents(rClient(grab), device, xE, count, mask,
+                                       GetEventFilter(device, xE), grab);
+            }
 
 	    if (grabinfo->sync.state == FROZEN_NO_EVENT)
 	    {
@@ -3571,6 +3630,8 @@ CheckPassiveGrabsOnWindow(
 		grabinfo->sync.state = FROZEN_WITH_EVENT;
             }
 
+            if (match & (XI_MATCH | XI2_MATCH))
+                xfree(xE); /* on core match xE == &core */
 	    return TRUE;
 	}
     }
commit 1242e494c8abc25d51fa0f8120ba353ffcf7be08
Author: Peter Hutterer <peter.hutterer at who-t.net>
Date:   Fri Mar 5 09:27:13 2010 +1000

    xserver 1.7.5.901
    
    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

diff --git a/configure.ac b/configure.ac
index 0726bd2..08e444e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -26,8 +26,8 @@ dnl
 dnl Process this file with autoconf to create configure.
 
 AC_PREREQ(2.57)
-AC_INIT([xorg-server], 1.7.5, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
-RELEASE_DATE="2010-02-16"
+AC_INIT([xorg-server], 1.7.5.901, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
+RELEASE_DATE="2010-03-05"
 AC_CONFIG_SRCDIR([Makefile.am])
 AM_INIT_AUTOMAKE([dist-bzip2 foreign])
 AM_MAINTAINER_MODE


More information about the xorg-commit mailing list