mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2025-10-29 05:40:21 -04:00
fix: noaime for layershell and not use animation for bottom and background layer
This commit is contained in:
parent
11eef5ea2d
commit
65d2642064
1 changed files with 5 additions and 8 deletions
13
src/maomao.c
13
src/maomao.c
|
|
@ -1003,13 +1003,6 @@ void fadeout_client_animation_next_tick(Client *c) {
|
|||
|
||||
void layer_animation_next_tick(LayerSurface *l) {
|
||||
|
||||
if (!animations || l->noanim) {
|
||||
wlr_scene_node_set_position(&l->scene->node, l->geom.x, l->geom.y);
|
||||
l->animation.passed_frames = 0;
|
||||
l->animation.running = false;
|
||||
l->need_output_flush = false;
|
||||
}
|
||||
|
||||
double animation_passed =
|
||||
(double)l->animation.passed_frames / l->animation.total_frames;
|
||||
|
||||
|
|
@ -1493,7 +1486,7 @@ bool layer_draw_frame(LayerSurface *l) {
|
|||
return false;
|
||||
}
|
||||
|
||||
if (animations && l->animation.running) {
|
||||
if (animations && l->animation.running && !l->noanim) {
|
||||
layer_animation_next_tick(l);
|
||||
} else {
|
||||
wlr_scene_node_set_position(&l->scene->node, l->geom.x, l->geom.y);
|
||||
|
|
@ -7363,6 +7356,10 @@ void init_fadeout_layers(LayerSurface *l) {
|
|||
return;
|
||||
}
|
||||
|
||||
if (l->layer_surface->current.layer == ZWLR_LAYER_SHELL_V1_LAYER_BOTTOM ||
|
||||
l->layer_surface->current.layer == ZWLR_LAYER_SHELL_V1_LAYER_BACKGROUND)
|
||||
return;
|
||||
|
||||
LayerSurface *fadeout_layer = ecalloc(1, sizeof(*fadeout_layer));
|
||||
|
||||
wlr_scene_node_set_enabled(&l->scene->node, true);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue