less negatives means less confusing.. but yeah. get rid of omnipresent check in focus_fallback

This commit is contained in:
Dana Jansens 2007-05-25 15:41:14 +00:00
parent cca8a90301
commit ad8e8d4988
2 changed files with 5 additions and 15 deletions

View file

@ -110,17 +110,6 @@ static ObClient* focus_fallback_target(gboolean allow_refocus, ObClient *old)
return c; return c;
} }
ob_debug_type(OB_DEBUG_FOCUS, "trying omnipresentness\n");
if (allow_refocus && old &&
old->desktop == DESKTOP_ALL &&
client_normal(old) &&
client_focus(old))
{
ob_debug_type(OB_DEBUG_FOCUS, "found in omnipresentness\n");
return old;
}
ob_debug_type(OB_DEBUG_FOCUS, "trying the focus order\n"); ob_debug_type(OB_DEBUG_FOCUS, "trying the focus order\n");
for (it = focus_order; it; it = g_list_next(it)) { for (it = focus_order; it; it = g_list_next(it)) {
c = it->data; c = it->data;

View file

@ -530,16 +530,17 @@ void screen_set_desktop(guint num, gboolean dofocus)
} }
} }
if (focus_client && (focus_client->desktop == DESKTOP_ALL ||
focus_client->desktop == screen_desktop))
dofocus = FALSE;
/* have to try focus here because when you leave an empty desktop /* have to try focus here because when you leave an empty desktop
there is no focus out to watch for there is no focus out to watch for
do this before hiding the windows so if helper windows are coming do this before hiding the windows so if helper windows are coming
with us, they don't get hidden with us, they don't get hidden
*/ */
if (dofocus if (dofocus && (c = focus_fallback(TRUE)))
&& (!focus_client || (focus_client->desktop != DESKTOP_ALL
&& focus_client->desktop != num))
&& (c = focus_fallback(TRUE)))
{ {
/* only do the flicker reducing stuff ahead of time if we are going /* only do the flicker reducing stuff ahead of time if we are going
to call xsetinputfocus on the window ourselves. otherwise there is to call xsetinputfocus on the window ourselves. otherwise there is