mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2026-04-18 06:47:02 -04:00
opt: optimize restore ov
This commit is contained in:
parent
fd6ca73907
commit
26634f28e4
1 changed files with 9 additions and 1 deletions
10
src/maomao.c
10
src/maomao.c
|
|
@ -6308,6 +6308,14 @@ void overview_restore(Client *c, const Arg *arg) {
|
||||||
c->bw = c->overview_backup_bw;
|
c->bw = c->overview_backup_bw;
|
||||||
c->animation.tagining = false;
|
c->animation.tagining = false;
|
||||||
c->is_restoring_from_ov = (arg->ui & c->tags & TAGMASK) == 0 ? true : false;
|
c->is_restoring_from_ov = (arg->ui & c->tags & TAGMASK) == 0 ? true : false;
|
||||||
|
|
||||||
|
if(!VISIBLEON(c, c->mon)) {
|
||||||
|
c->animation.current = c->current = c->pending = c->geom;
|
||||||
|
wlr_scene_node_set_enabled(&c->scene->node, false);
|
||||||
|
client_set_suspended(c, true);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (c->isfloating) {
|
if (c->isfloating) {
|
||||||
// XRaiseWindow(dpy, c->win); // 提升悬浮窗口到顶层
|
// XRaiseWindow(dpy, c->win); // 提升悬浮窗口到顶层
|
||||||
resize(c, c->overview_backup_geom, 0);
|
resize(c, c->overview_backup_geom, 0);
|
||||||
|
|
@ -6318,7 +6326,7 @@ void overview_restore(Client *c, const Arg *arg) {
|
||||||
} else {
|
} else {
|
||||||
c->isfullscreen = 0;
|
c->isfullscreen = 0;
|
||||||
c->ismaxmizescreen = 0;
|
c->ismaxmizescreen = 0;
|
||||||
client_set_fullscreen(c, false);
|
setfullscreen(c, false);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (c->is_restoring_from_ov) {
|
if (c->is_restoring_from_ov) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue