patch_for_1016.txt

fix white box - Steven Mizuno, 2008-08-20 05:33 PM

Download (850 Bytes)

 
1
Index: src/gui/qgsmapcanvas.cpp
2
===================================================================
3
--- src/gui/qgsmapcanvas.cpp	(revision 9071)
4
+++ src/gui/qgsmapcanvas.cpp	(working copy)
5
@@ -654,6 +654,18 @@
6
         }
7
         break;
8
 
9
+      case Qt::Key_PageUp:
10
+        QgsDebugMsg("Zoom in");
11
+
12
+        zoom(true);
13
+        break;
14
+
15
+      case Qt::Key_PageDown:
16
+        QgsDebugMsg("Zoom out");
17
+
18
+        zoom(false);
19
+        break;
20
+
21
       default:
22
         // Pass it on
23
         if(mMapTool)
24
@@ -798,10 +810,10 @@
25
     int height = lastSize.height();
26
     lastSize = QSize(-1,-1);
27
 
28
+    mMap->resize(QSize(width,height));
29
+
30
     mScene->setSceneRect(QRectF(0,0,width, height));
31
 
32
-    mMap->resize(QSize(width,height));
33
-
34
     // notify canvas items of change
35
     updateCanvasItemsPositions();
36