mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2025-11-21 06:59:53 -05:00
feat: add option zoom_end_ratio
This commit is contained in:
parent
4f44d3dd06
commit
d1cff55348
5 changed files with 15 additions and 10 deletions
|
|
@ -788,16 +788,16 @@ void init_fadeout_client(Client *c) {
|
|||
} else {
|
||||
fadeout_cient->current.y =
|
||||
(fadeout_cient->geom.height -
|
||||
fadeout_cient->geom.height * zoom_initial_ratio) /
|
||||
fadeout_cient->geom.height * zoom_end_ratio) /
|
||||
2;
|
||||
fadeout_cient->current.x =
|
||||
(fadeout_cient->geom.width -
|
||||
fadeout_cient->geom.width * zoom_initial_ratio) /
|
||||
fadeout_cient->geom.width * zoom_end_ratio) /
|
||||
2;
|
||||
fadeout_cient->current.width =
|
||||
fadeout_cient->geom.width * zoom_initial_ratio;
|
||||
fadeout_cient->geom.width * zoom_end_ratio;
|
||||
fadeout_cient->current.height =
|
||||
fadeout_cient->geom.height * zoom_initial_ratio;
|
||||
fadeout_cient->geom.height * zoom_end_ratio;
|
||||
}
|
||||
|
||||
fadeout_cient->animation.passed_frames = 0;
|
||||
|
|
|
|||
|
|
@ -408,10 +408,8 @@ void init_fadeout_layers(LayerSurface *l) {
|
|||
strcmp(layer_animation_type_close, "zoom") == 0) ||
|
||||
(l->animation_type_close &&
|
||||
strcmp(l->animation_type_close, "zoom") == 0)) {
|
||||
fadeout_layer->current.width =
|
||||
(float)l->geom.width * zoom_initial_ratio;
|
||||
fadeout_layer->current.height =
|
||||
(float)l->geom.height * zoom_initial_ratio;
|
||||
fadeout_layer->current.width = (float)l->geom.width * zoom_end_ratio;
|
||||
fadeout_layer->current.height = (float)l->geom.height * zoom_end_ratio;
|
||||
fadeout_layer->current.x = usable_area.x + usable_area.width / 2 -
|
||||
fadeout_layer->current.width / 2;
|
||||
fadeout_layer->current.y = usable_area.y + usable_area.height / 2 -
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue