image/zoom: Store pointer target through animation

Closes #48 #287
This commit is contained in:
Sophie Herold 2024-01-03 13:51:54 +01:00
parent a0e4791e6b
commit 56625f2309
2 changed files with 23 additions and 44 deletions

View file

@ -169,11 +169,7 @@ mod imp {
/// Targeted zoom level, might differ from `zoom` when animation is
/// running
pub(super) zoom_target: Cell<f64>,
/// Current animation is transitioning from having horizontal scrollbars
/// to not having them or vice versa.
pub(super) zoom_hscrollbar_transition: Cell<bool>,
/// Same but for vertical
pub(super) zoom_vscrollbar_transition: Cell<bool>,
pub(super) zoom_cursor_target: Cell<Option<(f64, f64)>>,
/// Always fit image into window, causes `zoom` to change automatically
#[property(get, set)]