image: Fix setting horizontal instead of vertical
Fix horizontal scrollbar sometimes jumping to center while zooming in.
This commit is contained in:
parent
229c63719e
commit
0b7e30af30
3 changed files with 13 additions and 1 deletions
|
|
@ -1426,7 +1426,7 @@ impl LpImage {
|
|||
let target_vborder = self.widget_height() - self.image_size().1 as f64 * zoom;
|
||||
|
||||
self.imp()
|
||||
.zoom_hscrollbar_transition
|
||||
.zoom_vscrollbar_transition
|
||||
.set(current_vborder.signum() != target_vborder.signum() && current_vborder != 0.);
|
||||
|
||||
let animation = self.zoom_animation();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue