]> err.no Git - libchamplain/commitdiff
Fix Bug 575139: Corrupted map when double clicking at max level
authorPierre-Luc Beaudoin <pierre-luc@pierlux.com>
Sun, 22 Mar 2009 20:52:29 +0000 (22:52 +0200)
committerPierre-Luc Beaudoin <pierre-luc@pierlux.com>
Sun, 22 Mar 2009 21:02:52 +0000 (23:02 +0200)
Even though the fix to 558020 also fixed this issue,
there was a slight undesirable translation happening.

champlain/champlain-view.c

index 127c3e74a18c77cda1178e27dc1e503678eced22..84d71ebacc6babed5cfe3be9381bb433935df8b2 100644 (file)
@@ -884,6 +884,11 @@ finger_scroll_button_press_cb (ClutterActor *actor,
 
   if (priv->zoom_on_double_click && event->button == 1 && event->click_count == 2)
     {
+      /* If at last zoom level, don't do anything */
+      if (priv->zoom_level ==
+          champlain_map_source_get_max_zoom_level (priv->map_source))
+        return FALSE;
+
       gint actor_x, actor_y;
       gint rel_x, rel_y;