get sel from focustop() in focusstack()

Fixes: https://github.com/djpohly/dwl/issues/354
This commit is contained in:
Leonardo Hernández Hernández 2022-12-09 20:55:58 -06:00
parent c60f651951
commit 94c8bd6048
No known key found for this signature in database
GPG key ID: E538897EE11B9624

2
dwl.c
View file

@ -1261,7 +1261,7 @@ void
focusstack(const Arg *arg) focusstack(const Arg *arg)
{ {
/* Focus the next or previous client (in tiling order) on selmon */ /* Focus the next or previous client (in tiling order) on selmon */
Client *c, *sel = selclient(); Client *c, *sel = focustop(selmon);
if (!sel || sel->isfullscreen) if (!sel || sel->isfullscreen)
return; return;
if (arg->i > 0) { if (arg->i > 0) {