try patch over a focus issue where a window looks focused but isnt.

SVN revision: 75935
This commit is contained in:
Carsten Haitzler 2012-09-02 03:17:54 +00:00
parent 6e8a7eef7e
commit 7a86fdce05
1 changed files with 19 additions and 4 deletions

View File

@ -2176,8 +2176,22 @@ e_border_focus_set(E_Border *bd,
else else
focus_next = eina_list_prepend(focus_next, bd); focus_next = eina_list_prepend(focus_next, bd);
} }
if ((bd->client.icccm.take_focus) &&
return; (bd->client.icccm.accepts_focus))
{
e_grabinput_focus(bd->client.win, E_FOCUS_METHOD_LOCALLY_ACTIVE);
/* TODO what if the client didn't take focus ? */
}
else if (!bd->client.icccm.accepts_focus)
{
e_grabinput_focus(bd->client.win, E_FOCUS_METHOD_GLOBALLY_ACTIVE);
}
else if (!bd->client.icccm.take_focus)
{
e_grabinput_focus(bd->client.win, E_FOCUS_METHOD_PASSIVE);
/* e_border_focus_set(bd, 1, 0); */
}
return;
} }
if (!bd->focused) if (!bd->focused)
@ -3414,14 +3428,15 @@ e_border_idler_before(void)
/* TODO revert focus when lost here ? */ /* TODO revert focus when lost here ? */
return; return;
} }
#if 0
if (bd == focused) if (bd == focused)
{ {
/* already focused. but anyway dont be so strict, this /* already focused. but anyway dont be so strict, this
fcks up illume setting focus on internal windows */ fcks up illume setting focus on internal windows */
return; return;
} }
#endif
focus_time = ecore_x_current_time_get(); focus_time = ecore_x_current_time_get();
focusing = bd; focusing = bd;