mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2025-11-07 13:29:59 -05:00
opt: optimize code struct
This commit is contained in:
parent
ba65b03443
commit
f5456f46f6
1 changed files with 9 additions and 9 deletions
18
src/mango.c
18
src/mango.c
|
|
@ -3900,15 +3900,6 @@ setfloating(Client *c, int floating) {
|
|||
if (!c || !c->mon || !client_surface(c)->mapped || c->iskilling)
|
||||
return;
|
||||
|
||||
if (c->isoverlay) {
|
||||
wlr_scene_node_reparent(&c->scene->node, layers[LyrOverlay]);
|
||||
} else if (client_should_overtop(c) && c->isfloating) {
|
||||
wlr_scene_node_reparent(&c->scene->node, layers[LyrFSorOverTop]);
|
||||
} else {
|
||||
wlr_scene_node_reparent(&c->scene->node,
|
||||
layers[c->isfloating ? LyrFloat : LyrTile]);
|
||||
}
|
||||
|
||||
target_box = c->geom;
|
||||
|
||||
if (floating == 1 && c != grabc) {
|
||||
|
|
@ -3961,6 +3952,15 @@ setfloating(Client *c, int floating) {
|
|||
}
|
||||
}
|
||||
|
||||
if (c->isoverlay) {
|
||||
wlr_scene_node_reparent(&c->scene->node, layers[LyrOverlay]);
|
||||
} else if (client_should_overtop(c) && c->isfloating) {
|
||||
wlr_scene_node_reparent(&c->scene->node, layers[LyrFSorOverTop]);
|
||||
} else {
|
||||
wlr_scene_node_reparent(&c->scene->node,
|
||||
layers[c->isfloating ? LyrFloat : LyrTile]);
|
||||
}
|
||||
|
||||
arrange(c->mon, false);
|
||||
setborder_color(c);
|
||||
printstatus();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue