XIScrollClassInfo, generation of "smooth" scroll events from replayed buttons

Peter Hutterer peter.hutterer at who-t.net
Mon Jun 15 21:53:31 PDT 2015


On Fri, Jun 12, 2015 at 09:21:34PM +0200, Thomas L├╝bking wrote:
> See https://bugzilla.gnome.org/show_bug.cgi?id=750870
> 
> KWin passively grabs and casually replays buttons (including 4,5,6 & 7) on
> inactive windows, but apparently that does not lead to the generation of
> "smooth" scroll events from xinput2.
> 
> I suspect this could be related to the replay also generating framing
> enter/leave events (at least I hope that's not somehow us causing them ;-)
> 
> => Is this somehow still supposed to work?

well, the problem here is that button and motion events are separate 
events and replaying an event only replays that event. The whole sequence
is:

<sigio handler>
1) driver submits scroll data as button event
2) server generates button and motion events
3) server adds events to event queue
<back to normal event loop>
4) server gets next event from queue (button press)
5) client has passive grab on button press
6) client replays event (button press)
7) server sends event to next client
goto 4, but now the event is the emulated scroll event

i.e. the smooth scroll emulation is not done on-the-fly but rather at the
event generation stage. so no, it's not possible to grab a button event and
have that replay as smooth scroll event. sorry.

Cheers,
   Peter


More information about the xorg mailing list