Axis events to keyboard focus (Re: Input and games.)

Pekka Paalanen ppaalanen at gmail.com
Sun May 5 23:40:42 PDT 2013


On Sun, 5 May 2013 15:27:54 -0400
Todd Showalter <todd at electronjump.com> wrote:

> On Sun, May 5, 2013 at 12:55 PM, Pekka Paalanen <ppaalanen at gmail.com> wrote:
> 
> > In a wl_seat, we have one kbd focus, and one pointer focus. These
> > two are unrelated, except sometimes some pointer action may change
> > the kbd focus. Most of the time, they have no relation.
> 
>     As a total aside, OSX has this and it drives me nuts.  Scrollwheel
> focus follows the pointer, keyboard focus doesn't.  In practise what
> that means is that whenever I'm on OSX I wind up closing the wrong
> thing.

Actual focus assignment is just server behaviour, an implementation
detail. We could as well have Wayland servers where keyboard focus
follows mouse, but...

sending pointer axis events (i.e. scroll wheel) to the window with
the keyboard focus is... unexplored. If it is ok to send axis events
outside of a wl_pointer.enter/leave pair, then it's perfectly doable.
Is it, I don't know. I don't see a reason it wouldn't work, if clients
can handle axis events without a pointer position.

>  Example:
> 
> - running an irc client and firefox
> - colleague sends an url, I click on it
> - firefox brings up the url, I mouse over to it and scroll through
> with the scroll wheel
> - I'm done with the link, clover-w to close the tab, and it closes my
> IRC session instead, because keyboard focus never left the irc window
> 
>     I've had to use OSX for a couple of years now because of some iOS
> projects we've been working on, and this still bites me at least once
> a day.  It's *completely* counterintuitive GUI behaviour.


Thanks,
pq


More information about the wayland-devel mailing list