summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2013-07-10 10:30:48 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2013-07-10 10:30:48 +1000
commit32f47024fc2e3d61c4bd483935381a301e4ed32c (patch)
treeab457a82b9d05c7a5413a68732929ee8a1ec5a86
parent8b660cd307297c13771996fa77fe366f98162305 (diff)
server/grab: fix test for ungrab during touch
A pointer-emulated touch grab must be accepted by the client with an ungrab, i.e. the client won't see any more events. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r--tests/server/grab.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/server/grab.cpp b/tests/server/grab.cpp
index c7147b7..052a3b7 100644
--- a/tests/server/grab.cpp
+++ b/tests/server/grab.cpp
@@ -2034,8 +2034,7 @@ TEST_F(TouchOwnershipTest, ActivePointerUngrabDuringTouch)
"TouchBegin in the window.\n"
"Expect ButtonPress to A.\n"
"Ungrab pointer.\n"
- "Expect TouchBegin and TouchOwnership to B.\n"
- "TouchEnd in the window, expect TouchEnd on B.\n");
+ "TouchEnd to B.\n");
::Display *dpy = Display();
XSynchronize(dpy, True);
@@ -2059,14 +2058,14 @@ TEST_F(TouchOwnershipTest, ActivePointerUngrabDuringTouch)
ASSERT_TRUE(NoEventPending(dpy2));
XIUngrabDevice(dpy, VIRTUAL_CORE_POINTER_ID, CurrentTime);
+ ASSERT_TRUE(NoEventPending(dpy));
- ASSERT_EVENT(XITouchOwnershipEvent, B_ownership, dpy2, GenericEvent, xi2_opcode, XI_TouchOwnership);
+ ASSERT_EVENT(XIDeviceEvent, B_end, dpy2, GenericEvent, xi2_opcode, XI_TouchEnd);
dev->Play(RECORDINGS_DIR "tablets/N-Trig-MultiTouch.touch_1_end.events");
- ASSERT_EVENT(XIDeviceEvent, B_end, dpy2, GenericEvent, xi2_opcode, XI_TouchEnd);
-
ASSERT_TRUE(NoEventPending(dpy));
+ ASSERT_TRUE(NoEventPending(dpy2));
}
#endif /* HAVE_XI22 */