From: Reginald Kennedy Date: Mon, 29 Oct 2012 15:06:45 +0000 (+0800) Subject: Map all top-level-windows in max_stack. X-Git-Url: https://jasonwoof.com/gitweb/?a=commitdiff_plain;h=3543a15189b01981db4666dfe2b7b8f9924a4f1b;p=spectrwm.git Map all top-level-windows in max_stack. Remove unused variable in max_stack. --- diff --git a/spectrwm.c b/spectrwm.c index 4b3eb86..42c8bd2 100644 --- a/spectrwm.c +++ b/spectrwm.c @@ -4442,7 +4442,7 @@ max_stack(struct workspace *ws, struct swm_geometry *g) { struct swm_geometry gg = *g; struct ws_win *w, *win = NULL, *parent = NULL; - int winno, num_screens; + int winno; DNPRINTF(SWM_D_STACK, "max_stack: workspace: %d\n", ws->idx); @@ -4467,11 +4467,13 @@ max_stack(struct workspace *ws, struct swm_geometry *g) DNPRINTF(SWM_D_STACK, "max_stack: win: 0x%x\n", win->id); /* maximize all top level windows */ - num_screens = xcb_setup_roots_length(xcb_get_setup(conn)); TAILQ_FOREACH(w, &ws->winlist, entry) { if (w->transient || w->iconic) continue; + if (!win->mapped && w != win) + map_window(w); + if (w->floating && !w->floatmaxed) { /* * retain geometry for retrieval on exit from