Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Tweak "show-desktop" feature behaviour.
Now if user activates a task while in showing desktop mode, the state of
a flag "showing_desktop" is being set to 0. That way code removes
requirement to click twice in order to show desktop again.
  • Loading branch information
nsf committed Jul 2, 2010
1 parent fec6c40 commit c996338
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions widget-taskbar.c
Expand Up @@ -668,8 +668,10 @@ static void button_click(struct widget *w, XButtonEvent *e)
if (mbutton_use) {
if (tw->active == t->win)
XIconifyWindow(c->dpy, t->win, c->screen);
else
else {
activate_task(c, t);
w->panel->showing_desktop = 0;
}
}
if (mbutton_kill)
close_task(c, t);
Expand Down Expand Up @@ -732,8 +734,10 @@ static void client_msg(struct widget *w, XClientMessageEvent *e)
int ti = get_taskbar_task_at(w, x - p->x);
if (ti != -1) {
struct taskbar_task *t = &tw->tasks[ti];
if (t->win != tw->active)
if (t->win != tw->active) {
activate_task(c, t);
w->panel->showing_desktop = 0;
}
}

x_send_dnd_message(c, e->data.l[0],
Expand Down

0 comments on commit c996338

Please sign in to comment.