mirror of
https://github.com/leahneukirchen/cwm.git
synced 2023-08-10 21:13:12 +03:00
Simplify conditional construct.
OK okan@
This commit is contained in:
parent
49f839e194
commit
6c7b8261df
7
kbfunc.c
7
kbfunc.c
@ -509,7 +509,6 @@ kbfunc_menu_client(void *ctx, struct cargs *cargs)
|
|||||||
struct client_ctx *cc, *old_cc;
|
struct client_ctx *cc, *old_cc;
|
||||||
struct menu *mi;
|
struct menu *mi;
|
||||||
struct menu_q menuq;
|
struct menu_q menuq;
|
||||||
int all = (cargs->flag & CWM_MENU_WINDOW_ALL);
|
|
||||||
int mflags = 0;
|
int mflags = 0;
|
||||||
|
|
||||||
if (cargs->xev == CWM_XEV_BTN)
|
if (cargs->xev == CWM_XEV_BTN)
|
||||||
@ -517,10 +516,8 @@ kbfunc_menu_client(void *ctx, struct cargs *cargs)
|
|||||||
|
|
||||||
TAILQ_INIT(&menuq);
|
TAILQ_INIT(&menuq);
|
||||||
TAILQ_FOREACH(cc, &sc->clientq, entry) {
|
TAILQ_FOREACH(cc, &sc->clientq, entry) {
|
||||||
if (!all) {
|
if ((cargs->flag & CWM_MENU_WINDOW_ALL) ||
|
||||||
if (cc->flags & CLIENT_HIDDEN)
|
(cc->flags & CLIENT_HIDDEN))
|
||||||
menuq_add(&menuq, cc, NULL);
|
|
||||||
} else
|
|
||||||
menuq_add(&menuq, cc, NULL);
|
menuq_add(&menuq, cc, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user