Re: _NET_WM_USER_TIME and initial window(s)...



On Monday 24 of January 2005 2:43, Elijah Newren wrote:
> Hi all,
>
> The CVS version of the EWMH spec states that clients should set the
> _NET_WM_USER_TIME property on every new toplevel window before mapping
> it.  However, it also states that clients shouldn't set this property
> before receiving first input event.  I believe the latter restriction
> is both unnecessary and harmful.
>
> The restriction was there, I believe, merely because when
> _NET_WM_USER_TIME was first introduced the app had no way to set it
> due to the fact that we used to use the TIMESTAMP property instead of
> having the timestamp be stored in the DESKTOP_STARTUP_ID environment
> variable.

 Most probably.

> However, this restriction causes problems in the following 
> case:
>   1) Launch Evolution
>   2) Click in some other window
>   3) The main Evolution window comes up
>   4) Evolution immediately pops up a dialog window asking for your password
> When the Evolution window comes up, the WM can use the _NET_STARTUP_ID
> property (or the TIMESTAMP property if dealing with older startup
> notification launchers) to find the timestamp it was launched with.
> Thus, the main Evolution window is correctly placed behind the current
> window with the DEMANDS_ATTENTION hint set.  However, for the dialog
> that pops up immediately afterward, there is no timestamp to compare
> so the window manager gives it focus--against the user's wishes.

 Actually it is possible to prevent that window from showing up simply by 
checking its window relations. The dialog is for another window, so if it 
doesn't have its own timestamp, the WM can check the related window. This 
specific problem most probably doesn't exist with KWin.

[...]
> So, I would like to request that we remove the restriction on setting
> _NET_WM_USER_TIME only after the first user interaction.  Would this
> be okay?  I made a patch to do this (which I have attached), but I

 I can see you don't use KMail ;).

> also made some other cleanups/clarifications.  Please check it to make
> sure I didn't accidentally introduce any problems.

 The original intention of that sentence was to prevent applications from 
using some arbitrary value (like current X timestamp or 0) in case they don't 
know the real value. Your change seems fine, except that I'd prefer to see it 
formulated as "it should not set the property" (need not -> should not).
 
-- 
Lubos Lunak
KDE developer
---------------------------------------------------------------------
SuSE CR, s.r.o.  e-mail: l lunak suse cz , l lunak kde org
Drahobejlova 27  tel: +420 2 9654 2373
190 00 Praha 9   fax: +420 2 9654 2374
Czech Republic   http://www.suse.cz/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]