[QGIS Commit] r13500 - trunk/qgis/src/gui

svn_qgis at osgeo.org svn_qgis at osgeo.org
Sun May 16 10:38:12 EDT 2010


Author: jef
Date: 2010-05-16 10:38:12 -0400 (Sun, 16 May 2010)
New Revision: 13500

Modified:
   trunk/qgis/src/gui/qgsmapcanvas.cpp
Log:
temporary workaround for #2714

Modified: trunk/qgis/src/gui/qgsmapcanvas.cpp
===================================================================
--- trunk/qgis/src/gui/qgsmapcanvas.cpp	2010-05-16 14:22:06 UTC (rev 13499)
+++ trunk/qgis/src/gui/qgsmapcanvas.cpp	2010-05-16 14:38:12 UTC (rev 13500)
@@ -960,7 +960,12 @@
     updateCanvasItemPositions();
 
     updateScale();
+#if QT_VERSION >= 0x40600
+    // FIXME: temporary workaround for #2714
+    QTimer::singleShot( 1, this, SLOT( refresh() ) );
+#else
     refresh();
+#endif
     emit extentsChanged();
   }
   isAlreadyIn = false;
@@ -1435,8 +1440,7 @@
 void QgsMapCanvas::selectionChangedSlot()
 {
   // Find out which layer it was that sent the signal.
-  QgsMapLayer * layer = ( QgsMapLayer * )QObject::sender();
-
+  QgsMapLayer *layer = qobject_cast<QgsMapLayer *>( sender() );
   emit selectionChanged( layer );
   refresh();
 }



More information about the QGIS-commit mailing list