client thus always falling back to client_current(); while the current client
is problaby right in most cases, use event's subwindow (not window) to find the
client. Bail early if this event came to us from a screen we don't manage.
This is result of us grabing all keybindings off the root window instead of
selectively.
via property notify events. Previously only the flags were set but nothing was
in the path to apply said flags and/or bwidth. Required slight of re-orgnaization
of client_init.
into the keyrelease event, only performing what's actually needed for each;
should result in much fewer events against keyreleases. No intended behaviour
change.
Additionally, like we do for group membership, grab the keyboard only when
required for cycling.
client_ctx in keypress and buttonpress event handlers; pass appropriate *ctx's
based on context.
While here, limit some globals, replace defines with appropriate variables and
fix some naming.
key press. This allows to remove a few hacks to duplicate functions only
for behaviour changes; now differing behaviours are pushed down to the
callback. Also will allow for previously unavailable actions to be bind-able
down the road.
the screen; adapted from an ancient diff from Sviatoslav Chagaev. Things
in this area will likely change, but put this in so it works now and
serves as a reminder.
active; while we already look at what's under the pointer, use this
information first, then look under the pointer (saving that round-trip).
This restores the active state to a client after restart even if the
pointer is not above it (and of course the pointer is not above another
client).
client_find valid resources as needed, relieving the need for
screen_find to ungracefully handle invalid root windows. Removes a long
standing XXX. Should theoretically allow XClientMessage handling on
more than one X screen. Alter callers of screen_find to handle
failures.
to having to manage an array outside in screen_ctx for group names and
shortcuts. Simplifies (and moves bits for) reading, and constructing
data for, EWMH's _NET_DESKTOP_NAMES.
clients) directly into client_init, performing the X roundtrip only
once. With the previous change in maprequest, this moves decision making
into one place for creating new clients.
then the window should appear on all desktops, which in our case is
assigned to group 0. Found to fix stalonetray due to the non-ewmh aware
range checking in group_movetogroup(); from Thomas Adam.
change allows a restart to trigger proper teardown first, even though
teardown is not (yet) complete.
After some discussion with oga@nicotinebsd.org regarding a more
complicated version/idea.
ewmh hint; urgencyborder is configurable. The urgency flag will stick,
even while on a client in a non-viewable group, until the client
receives focus (where the border is reset). Initial diff from Thomas
Adam with some changes/enhancements from me.
used for focus events, but rather the timestamp of the generated event.
Track the last event timestamp and send it down for a WM_TAKE_FOCUS
ClientMessage. I suspect we should do this for clients that don't
announce this Atom as well, though the raciness gets us into a bind.
Solves focus order issue since WM_TAKE_FOCUS; fix verified by sthen@
ok sthen@