[Xfce4-commits] [xfce/xfwm4] 01/01: focus: Ignore zero timestamp from s/n
noreply at xfce.org
noreply at xfce.org
Fri May 15 08:50:43 CEST 2015
This is an automated email from the git hooks/post-receive script.
olivier pushed a commit to branch xfce-4.12
in repository xfce/xfwm4.
commit 1ccf0fbdd1f8960a904e045099f4917e306b3cae
Author: Olivier Fourdan <fourdan at xfce.org>
Date: Fri May 15 08:43:05 2015 +0200
focus: Ignore zero timestamp from s/n
Applications may set their _NET_WM_USER_TIME to 0 to indicate that the
window should not initially focused when it is mapped, but there is no
indication that startup-notification given timstamp should follow the
same rule.
Ignore zero timestamp from startup-notification, it will help with apps
not being focused when started from the panel or the desktop.
Signed-off-by: Olivier Fourdan <fourdan at xfce.org>
---
src/focus.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/src/focus.c b/src/focus.c
index 0a8f333..183f4e8 100644
--- a/src/focus.c
+++ b/src/focus.c
@@ -159,8 +159,13 @@ clientFocusNew(Client * c)
{
give_focus = FALSE;
}
- else if (FLAG_TEST (c->flags, CLIENT_FLAG_HAS_STARTUP_TIME | CLIENT_FLAG_HAS_USER_TIME) && (c->user_time == (guint32) 0))
+ else if (FLAG_TEST (c->flags, CLIENT_FLAG_HAS_USER_TIME) && (c->user_time == (guint32) 0))
{
+ /*
+ * _NET_WM_USER_TIME definition from http://standards.freedesktop.org/wm-spec
+ * [...] "The special value of zero on a newly mapped window can be used to
+ * request that the window not be initially focused when it is mapped."
+ */
TRACE ("Given startup time is nil, not focusing \"%s\"", c->name);
give_focus = FALSE;
prevented = FALSE;
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list