Teach client_current() to use a screen to find the current client instead of

iterating over all (fallback if no screen provided for now). Initially convert
trivial uses of client_current().
This commit is contained in:
okan
2019-03-07 14:28:17 +00:00
parent 01be5b4e4a
commit 7c45b87622
4 changed files with 19 additions and 12 deletions

View File

@ -470,7 +470,7 @@ kbfunc_menu_client(void *ctx, struct cargs *cargs)
if (cargs->xev == CWM_XEV_BTN)
mflags |= CWM_MENU_LIST;
old_cc = client_current();
old_cc = client_current(sc);
TAILQ_INIT(&menuq);
TAILQ_FOREACH(cc, &sc->clientq, entry) {