Skip to content
Snippets Groups Projects
Commit a16a251a authored by Olivier Fourdan's avatar Olivier Fourdan
Browse files

Make sure the 'demand attention' flags gets cleared on focus.

(Old svn revision: 22146)
parent ac418017
No related branches found
No related tags found
No related merge requests found
......@@ -503,6 +503,11 @@ clientSetFocus (ScreenInfo *screen_info, Client * c, Time timestamp, unsigned sh
if ((c) && FLAG_TEST (c->xfwm_flags, XFWM_FLAG_VISIBLE))
{
TRACE ("setting focus to client \"%s\" (0x%lx)", c->name, c->window);
if (FLAG_TEST(c->flags, CLIENT_FLAG_DEMANDS_ATTENTION))
{
FLAG_UNSET (c->flags, CLIENT_FLAG_DEMANDS_ATTENTION);
clientSetNetState (c);
}
if ((c == client_focus) && !(flags & FOCUS_FORCE))
{
TRACE ("client \"%s\" (0x%lx) is already focused, ignoring request",
......@@ -523,11 +528,6 @@ clientSetFocus (ScreenInfo *screen_info, Client * c, Time timestamp, unsigned sh
{
sendClientMessage (c->screen_info, c->window, WM_TAKE_FOCUS, timestamp);
}
if (FLAG_TEST(c->flags, CLIENT_FLAG_DEMANDS_ATTENTION))
{
FLAG_UNSET (c->flags, CLIENT_FLAG_DEMANDS_ATTENTION);
clientSetNetState (c);
}
}
else
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment