Age | Commit message (Collapse) | Author | Files | Lines |
|
RawEvents are supposed to be events coming from the driver. When warping the
pointer, this should not generate a raw event.
X.Org Bug 30068 <http://bugs.freedesktop.org/show_bug.cgi?id=30068>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 23a783278963919778d017965542e0f983814e37)
Conflicts:
dix/getevents.c
|
|
Grabbing an SD device temporary floats the device but we must not release
the buttons. Introduced in
commit 9d23459415b84606ee4f38bb2d19054c432c8552
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date: Fri Feb 25 11:08:19 2011 +1000
dix: release all buttons and keys before reattaching a device (#34182)
X.Org Bug 36146 <http://bugs.freedesktop.org/show_bug.cgi?id=36146>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit bf2059b07a97e5e579c13c2c9d49707093427dc2)
Conflicts:
dix/devices.c
|
|
Testcase:
xinput float <keyboard name>
results in the keyboard's enter key being repeated as the device is detached
while the key is still physically down. To avoid this, release all keys and
buttons before reattaching the device.
X.Org Bug 34182 <http://bugs.freedesktop.org/show_bug.cgi?id=34182>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Fernando Carrijo <fcarrijo@freedesktop.org>
(cherry picked from commit 9d23459415b84606ee4f38bb2d19054c432c8552)
(cherry picked from commit 81fbb96c54f78a7cd96433294ee003c7ef6a772a)
|
|
event type, not device type.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit f94898928dfaf8df648bc3eea7d304826b7ac1b8)
Conflicts:
dix/events.c
|
|
When we change the root window's background to None, and we've run with
-wr or -br for a forced solid background, make sure we also change the
background state to BackgroundPixel, so we don't try to lookup either
pScreen->whitePixel or pScreen->blackPixel as a pixmap.
Signed-off-by: Marko Macek <Marko.Macek@gmx.net>
Reviewed-by: Walter Harms <wharms@bfs.de>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit c5b72fd350bbdfd1facd0ddd5085f238c4cf252a)
|
|
Found-by: GuardMalloc
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 25191648b8db87735a99243697f73036255c1eb6)
|
|
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Simon Thum <simon.thum@gmx.de>
(cherry picked from commit 8c528c667da7c7fba0ba07973a06b2d4613fbf70)
|
|
commit 678f5396c91b3d0c7572ed579b0a4fb62b2b4655 only fixed the
initialization, not the copy. After a slave device change, the valuator
were out of alignment again.
X.Org Bug 36119 <http://bugs.freedesktop.org/show_bug.cgi?id=36119>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 419a27b5219a739f2fbd50cc96a1b54c469e4a88)
|
|
This patch introduced a regression, reverting for the 1.10.1 release. See
https://bugs.freedesktop.org/show_bug.cgi?id=36146
This reverts commit 81fbb96c54f78a7cd96433294ee003c7ef6a772a.
|
|
Set the valuator values for unset masked absolute valuators in the
internal device event. This ensures the values will always be correct in
getValuatorEvents even if the device has been removed.
Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit b28a1af55cf1ad2a882cc8cd73b77341dec7ff5a)
|
|
Relative valuator values should not be reported in any future events. If
a relative valuator value is not set in an internal event, set the value
to 0 for XI 1.x valuator events sent over the wire.
Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
Reviewed-by: Simon Thum <simon.thum@gmx.de>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit f40103cee1d591387359f401a5a7c21f4105aeb4)
|
|
This allows for masked valuators to be handled properly in XI 1.x
events. Any unset valuators in the device event are set to the last
known value when transmitted on the wire through XI 1.x valuator events.
Fixes https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/736500
Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 8199eac443d2c22d313cb23e39d5e607a8cc7f99)
|
|
Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit ac00ab77d5a00cfd198958aa1afaa4c3ccc6d7bc)
|
|
When delivering an event to a device grabbed with SyncBoth,
DeliverGrabbedEvent walks the device tree looking for associated devices
to freeze them. Unfortunately, it froze all devices instead of just the
paired device, and the previous fix in 4fbadc8b17237f3c would still break
if the same client had a non-SyncBoth grab on another unrelated master
device.
Fix this by completely ignoring devices that aren't our paired device.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit b636893137da1695e235e3a9354bfd9243fdddc2)
|
|
Testcase:
xinput float <keyboard name>
results in the keyboard's enter key being repeated as the device is detached
while the key is still physically down. To avoid this, release all keys and
buttons before reattaching the device.
X.Org Bug 34182 <http://bugs.freedesktop.org/show_bug.cgi?id=34182>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Fernando Carrijo <fcarrijo@freedesktop.org>
(cherry picked from commit 9d23459415b84606ee4f38bb2d19054c432c8552)
|
|
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Nicolas Peninguy <nico@lostgeeks.org>
|
|
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Nicolas Peninguy <nico@lostgeeks.org>
|
|
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Nicolas Peninguy <nico@lostgeeks.org>
|
|
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Nicolas Peninguy <nico@lostgeeks.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Nicolas Peninguy <nico@lostgeeks.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Mikhail Gusarov <dottedmag@dottedmag.net>
Reviewed-by: Nicolas Peninguy <nico@lostgeeks.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
Signed-off-by: Rami Ylimäki <rami.ylimaki@vincit.fi>
Reviewed-by: Erkki Seppälä <erkki.seppala@vincit.fi>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 8d30aff4aa708b9b885d492602ced7493a96a4df)
|
|
Let the compiler figure out the correct alignment for the axes data
for a valuator by using a union to force double alignment of the
initial ValuatorClassRec structure in the allocation.
Signed-off-by: Keith Packard <keithp@keithp.com>
Tested-by: Julien Cristau <jcristau@debian.org>
Reviewed-by: Julien Cristau <jcristau@debian.org>
|
|
For all but motion and proximity events, having no valuators is ok.
Regression from 1.9, keyboard events are not converted to protocol events.
X.Org Bug 34510 <http://bugs.freedesktop.org/show_bug.cgi?id=34510>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Tested-by: Timo Aaltonen <timo.aaltonen@canonical.com>
|
|
|
|
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
|
This is clearly meant to short-circuit the (modestly) expensive resource
lookup in LegalNewID. The problem is that long-lived clients will
eventually run completely through their XID space and start asking
XC-MISC for IDs to reuse. Once that happens, the comparison against
expectID will always be true, and we'll no longer catch XID collisions
at all.
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
|
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
|
into for-keith
|
|
Expecting the caller to free the mask requires us to keep it in a single
memory block (which may be an issue lateron), aside from leaving the API
asymetrical. Provide valuator_mask_free() to free the memory and reset the
mask pointer to NULL.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Fernando Carrijo <fcarrijo@freedesktop.org>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
|
|
The code to set sync.other in DeliverGrabbedEvents is supposed to reset
sync.other for a paired MD to the grab under consideration, but was
rather optimistic in resetting sync.other for _all_ devices.
This would fall apart given two sets of MDs (A paired with B, Y paired
with Z), where both MDs were in FREEZE_BOTH_NEXT_EVENT due to being
called with SyncBoth, where no event had yet triggered the grab. An
event being processed on MD A would result in B, Y and Z all having
sync.other set to A's grab, rather than just B.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
Change CheckPassiveGrabsOnWindow to return the GrabPtr it used (or NULL
if none) rather than a boolean, and export it. Also add an additional
boolean 'activate' parameter; use TRUE for existing behaviour, or FALSE
to only find the grab and then return it.
This will be used in forthcoming touch patches to find the grabs, rather
than open-coding same.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
Make it non-static, add to headers.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
|
|
Don't try to search for an Xi 1.x grab in CheckPassiveGrabsOnWindow for
events with no Xi 1.x equivalent.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
|
|
XYToWindow calculates the position of the cursor and updates the sprite
trace, but does nothing else with the device. Pass a SpritePtr instead
so we can update an alternate focus instead of hardcoding the device's
sprite. Also make this function non-static, so we can use it elsewhere.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
|
|
Since FixUpEventFromWindow only uses the sprite trace to determine the
window stack, pass in a sprite instead of hardcoding the device sprite,
so we can deliver to windows other than the one currently containing the
sprite.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
|
|
GetCurrentRootWindow already works for the device case, although not as
an lvalue.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
|
|
Rename compUpdateWindow to compPaintWindowToParent and split the child
walk to compPaintChildrenToWindow. Calling compPaintChildrenToWindow
allows an arbitrary subtree to be updated, instead of having to update
all the windows. This will be used to make sure all the descendants are
copied to the parent when the parent window contents need to be accessed
in IncludeInferios sub-window mode.
WindowRec has a new member 'damagedDescendants' that is used to keep
track of which subtrees need updating. When a window is damaged,
'damagedDescendants' will be set for all the ancestors, and when a
subtree is updated, the tree walk can be stopped early if no damaged
descendants are present.
CompScreenRec no longer needs the 'damaged' member since the root
window's 'damagedDescendants' provides the same information.
Signed-off-by: Ville Syrjälä <ville.syrjala@nokia.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
This enables us to reliably inspect properties when destroying windows.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Fernando Carrijo <fcarrijo@freedesktop.org>
|
|
Will be used outside dix/events.c in proceeding XI 2.1 MT changes.
Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
The definition of rClient was duplicated across three source files, so
move it to resource.h.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
This was introduced in 3ab6cd31cbdf8095b2948034fce5fb645422d8da. Mea
culpa. This logic is still incorrect [1], but at least it's less
incorrect.
[1] - https://bugzilla.redhat.com/658587
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
|
Add a few checks for the existence of a valuator class on the device to
avoid null-pointer dereferences for button events from devices without a
valuator class.
X.Org Bug 21457 <http://bugs.freedesktop.org/show_bug.cgi?id=21457>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
|
|
No functional changes, just improves readability. This statement had things
added to/removed from it for a few server releases while the input event
queue was revamped. What made sense once is now mainly confusing.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
|
|
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Mikhail Gusarov <dottedmag@dottedmag.net>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Reviewed-by: Mikhail Gusarov <dottedmag@dottedmag.net>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Mikhail Gusarov <dottedmag@dottedmag.net>
|
|
As pointed out by Jamey Sharp (again), the logic is faulty: --warn is
always going to be false. Replace it with warn-- accordingly, so that
there's (at least, but also only) one warning showing up.
Reviewed-by: Jamey Sharp <jamey@minilop.net>
Signed-off-by: Cyril Brulebois <kibi@debian.org>
|
|
As pointed out by Jamey Sharp: “the result pointer is already guaranteed
to be NULL if the return value is not Success”, so get rid of the
variable used to catch the return value, and used in a ternary operation
to decide whether to return the pointer or NULL. Always return the
result pointer instead.
Reviewed-by: Jamey Sharp <jamey@minilop.net>
Signed-off-by: Cyril Brulebois <kibi@debian.org>
|