On Mon, Jul 08, 2019 at 11:04:10AM -0400 I heard the voice of
Stefan Monnier, and lo! it spake thus:
> 
> Hmm... so is it because we changed PRI(owl) without changing the
> OtpWinList accordingly, [...]

Yes[0].  The PRI() of the transient changed when the main window
gained focus, but it's still down among the normal windows where it
was prior.

We don't _move_ the transient to a new priority; it's just THERE as
soon as its master has focus.  's why the solution I wound up with was
that we just needed OTP entry points that explictly say "do {un,}focus
stuff", rather than the previous "restack this window", so it knows it
needs to explicitly handle already-unsorted stuff as part of the
action.


> IIRC we already had code doing something along those lines, more
> specifically code that raises its transients when we raise a normal
> window (see RaiseSmallTransientsOfAbove).

Yes, but that has two issues.  One, it only does _Small_ transients,
so misses larger one.  And the other (and the reason I couldn't just
use TryToMoveTransientsOfTo()) is that it embeds assumptions about how
to find the transients, which aren't effective since it's not where
its priority would indicate in the list (heck, if it were, we wouldn't
be eating the assertion fail, either...).


> I missed this change.  I'm not very familiar with FULLSCREEN.  Why
> do we need to change the OTP depending on focus?

https://specifications.freedesktop.org/wm-spec/wm-spec-1.3.html#STACKINGORDER

   * [on the top of everything] focused windows having state
     _NET_WM_STATE_FULLSCREEN


> Can you point me to the code which changes the "OTP" in response to
> focus change?

That happens in OwlEffectivePriority() (which PRI() is just a call
to).

https://bazaar.launchpad.net/~ctwm/ctwm/trunk/view/head:/otp.c#L1654




[0] In my case.  I'm still going with the assumption that Olaf's is
    closely related, except his seems to happen on _un_focus rather
    than focus, but we haven't managed to verify it yet.



-- 
Matthew Fuller     (MF4839)   |  [email protected]
Systems/Network Administrator |  http://www.over-yonder.net/~fullermd/
           On the Internet, nobody can hear you scream.

Reply via email to