static void focus_cycle_destructor(ObClient *client, gpointer data)
{
- /* end cycling if the target disappears */
+ /* end cycling if the target disappears. CurrentTime is fine, time won't
+ be used
+ */
if (focus_cycle_target == client)
- focus_cycle(TRUE, TRUE, TRUE, TRUE, TRUE, TRUE);
+ focus_cycle(TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, CurrentTime);
}
static Window createWindow(Window parent, gulong mask,
XSync(ob_display, FALSE);
}
- /* in the middle of cycling..? kill it. */
+ /* in the middle of cycling..? kill it. CurrentTime is fine, time won't
+ be used.
+ */
if (focus_cycle_target)
- focus_cycle(TRUE, TRUE, TRUE, TRUE, TRUE, TRUE);
+ focus_cycle(TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, CurrentTime);
old = focus_client;
focus_client = client;
active = client ? client->window : None;
PROP_SET32(RootWindow(ob_display, ob_screen),
net_active_window, window, active);
+
+ /* remove hiliting from the window when it gets focused */
+ if (client != NULL)
+ client_hilite(client, FALSE);
}
}
gint wt, wl, wr, wb;
wt = wl = wr = wb = MAX(3,
- ob_rr_theme->top_grip_height +
+ MAX(1, MAX(ob_rr_theme->paddingx,
+ ob_rr_theme->paddingy)) * 2 +
ob_rr_theme->fbwidth * 2);
x = focus_cycle_target->frame->area.x;
ft->type == OB_CLIENT_TYPE_MENU ||
ft->type == OB_CLIENT_TYPE_UTILITY))) &&
((ft->can_focus || ft->focus_notify) &&
- !ft->skip_taskbar &&
+ !ft->skip_pager &&
(ft->desktop == screen_desktop || ft->desktop == DESKTOP_ALL)) &&
ft == client_focus_target(ft))
return TRUE;
}
void focus_cycle(gboolean forward, gboolean linear, gboolean interactive,
- gboolean dialog, gboolean done, gboolean cancel)
+ gboolean dialog, gboolean done, gboolean cancel, Time time)
{
static ObClient *first = NULL;
static ObClient *t = NULL;
done_cycle:
if (done && focus_cycle_target)
- client_activate(focus_cycle_target, FALSE, TRUE);
+ client_activate(focus_cycle_target, FALSE, TRUE, time);
t = NULL;
first = NULL;
}
void focus_directional_cycle(ObDirection dir, gboolean interactive,
- gboolean dialog, gboolean done, gboolean cancel)
+ gboolean dialog, gboolean done, gboolean cancel,
+ Time time)
{
static ObClient *first = NULL;
ObClient *ft = NULL;
done_cycle:
if (done && focus_cycle_target)
- client_activate(focus_cycle_target, FALSE, TRUE);
+ client_activate(focus_cycle_target, FALSE, TRUE, time);
first = NULL;
focus_cycle_target = NULL;