From 313be97b2195d201de607464c210a10717457950 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20Ka=CC=88fer?= Date: Mon, 14 Apr 2014 19:33:05 -0400 Subject: [PATCH] animate double click zooming --- common/map_view.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/map_view.cpp b/common/map_view.cpp index 8957c2f43..478122fa5 100644 --- a/common/map_view.cpp +++ b/common/map_view.cpp @@ -147,8 +147,8 @@ public: if (action == GLFW_RELEASE) { mapView->map.stopPanning(); double now = glfwGetTime(); - if (now - mapView->last_click < 0.4) { - mapView->map.scaleBy(2.0, mapView->last_x, mapView->last_y); + if (now - mapView->last_click < 0.4 /* ms */) { + mapView->map.scaleBy(2.0, mapView->last_x, mapView->last_y, 0.5); } mapView->last_click = now; }