ENH: modify zoom interaction

Change-Id: I7a888a8980b5b10e5d2c515158c9c4cdf8654b7c
This commit is contained in:
liz.li authored and Lane.Wei committed 2023-04-17 15:39:02 +08:00
1 parent 62df53f86e
commit 87df72a67f
3 files changed
+8 -1

No files matched your search

+2 -1
View File
@@ -3596,7 +3596,8 @@ void GLCanvas3D::on_mouse_wheel(wxMouseEvent& evt)
double direction_factor = 1.0;
#endif
auto delta = direction_factor * (double)evt.GetWheelRotation() / (double)evt.GetWheelDelta();
if (evt.CmdDown()) {
bool zoom_to_mouse = wxGetApp().app_config->get("zoom_to_mouse") == "true";
if (!zoom_to_mouse) {// zoom to center
_update_camera_zoom(delta);
}
else {