mirror of
https://github.com/emilk/egui.git
synced 2026-09-02 14:50:03 -04:00
Fix auto_bounds when only one axis has restricted navigation (#3171)
This commit is contained in:
@@ -864,7 +864,7 @@ impl Plot {
|
|||||||
delta.y = 0.0;
|
delta.y = 0.0;
|
||||||
}
|
}
|
||||||
transform.translate_bounds(delta);
|
transform.translate_bounds(delta);
|
||||||
bounds_modified = true.into();
|
bounds_modified = allow_drag;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Zooming
|
// Zooming
|
||||||
@@ -935,7 +935,7 @@ impl Plot {
|
|||||||
}
|
}
|
||||||
if zoom_factor != Vec2::splat(1.0) {
|
if zoom_factor != Vec2::splat(1.0) {
|
||||||
transform.zoom(zoom_factor, hover_pos);
|
transform.zoom(zoom_factor, hover_pos);
|
||||||
bounds_modified = true.into();
|
bounds_modified = allow_zoom;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if allow_scroll {
|
if allow_scroll {
|
||||||
|
|||||||
Reference in New Issue
Block a user