mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2026-07-02 00:06:12 -04:00
fix: fix shield and blur node offset
This commit is contained in:
parent
88d32bdf8f
commit
5337405c31
2 changed files with 10 additions and 6 deletions
|
|
@ -366,6 +366,7 @@ void client_draw_title(Client *c) {
|
|||
void apply_shield(Client *c, struct wlr_box clip_box) {
|
||||
|
||||
if (clip_box.width <= 0 || clip_box.height <= 0) {
|
||||
wlr_scene_node_set_enabled(&c->shield->node, false);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -887,6 +888,14 @@ void client_apply_clip(Client *c, float factor) {
|
|||
apply_shield(c, clip_box);
|
||||
|
||||
if (clip_box.width <= 0 || clip_box.height <= 0) {
|
||||
should_render_client_surface = false;
|
||||
wlr_scene_node_set_enabled(&c->scene_surface->node, false);
|
||||
} else {
|
||||
should_render_client_surface = true;
|
||||
wlr_scene_node_set_enabled(&c->scene_surface->node, true);
|
||||
}
|
||||
|
||||
if (!should_render_client_surface) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1330,10 +1330,6 @@ void client_replace(Client *c, Client *w, bool is_group_change_member,
|
|||
mango_group_bar_set_focus(c->group_bar, c->isgroupfocusing);
|
||||
|
||||
if (w->overview_scene_surface) {
|
||||
|
||||
wlr_scene_node_reparent(&w->shield->node, w->overview_scene_surface);
|
||||
wlr_scene_node_raise_to_top(&w->shield->node);
|
||||
|
||||
wlr_scene_node_destroy(&w->scene_surface->node);
|
||||
w->scene_surface = w->overview_scene_surface;
|
||||
w->overview_scene_surface = NULL;
|
||||
|
|
@ -6737,7 +6733,6 @@ void unmapnotify(struct wl_listener *listener, void *data) {
|
|||
c->ext_foreign_toplevel = NULL;
|
||||
}
|
||||
|
||||
|
||||
if (c->swallowing) {
|
||||
setmaximizescreen(c->swallowing, c->ismaximizescreen, true);
|
||||
setfullscreen(c->swallowing, c->isfullscreen, true);
|
||||
|
|
@ -6754,7 +6749,7 @@ void unmapnotify(struct wl_listener *listener, void *data) {
|
|||
mango_jump_label_node_destroy(c->jump_label_node);
|
||||
c->jump_label_node = NULL;
|
||||
}
|
||||
|
||||
|
||||
if (c->group_bar) {
|
||||
mango_group_bar_destroy(c->group_bar);
|
||||
c->group_bar = NULL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue