diff --git a/src/maomao.c b/src/maomao.c index 8a555d3..3f51edd 100644 --- a/src/maomao.c +++ b/src/maomao.c @@ -6440,7 +6440,13 @@ void togglefloating(const Arg *arg) { if (!sel) return; - setfloating(sel, !sel->isfloating); + if ((sel->isfullscreen || sel->ismaxmizescreen)) { + sel->isfloating = 1; + } else { + sel->isfloating = !sel->isfloating; + } + + setfloating(sel, sel->isfloating); } void togglefakefullscreen(const Arg *arg) {