[QGIS Commit] r15174 - in trunk/qgis/src: app/legend core
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Tue Feb 15 02:22:37 EST 2011
Author: mhugent
Date: 2011-02-14 23:22:37 -0800 (Mon, 14 Feb 2011)
New Revision: 15174
Modified:
trunk/qgis/src/app/legend/qgslegendlayer.cpp
trunk/qgis/src/core/qgsvectorlayer.cpp
Log:
Fix for other multiple redraws
Modified: trunk/qgis/src/app/legend/qgslegendlayer.cpp
===================================================================
--- trunk/qgis/src/app/legend/qgslegendlayer.cpp 2011-02-15 06:21:15 UTC (rev 15173)
+++ trunk/qgis/src/app/legend/qgslegendlayer.cpp 2011-02-15 07:22:37 UTC (rev 15174)
@@ -340,7 +340,16 @@
// TODO: projection error icon?
QIcon theIcon( newIcon );
+ QgsLegend* l = legend();
+ if ( l )
+ {
+ l->blockSignals( true ); //prevent unnecessary canvas redraw
+ }
setIcon( 0, theIcon );
+ if ( l )
+ {
+ l->blockSignals( false );
+ }
}
QPixmap QgsLegendLayer::getOriginalPixmap()
Modified: trunk/qgis/src/core/qgsvectorlayer.cpp
===================================================================
--- trunk/qgis/src/core/qgsvectorlayer.cpp 2011-02-15 06:21:15 UTC (rev 15173)
+++ trunk/qgis/src/core/qgsvectorlayer.cpp 2011-02-15 07:22:37 UTC (rev 15174)
@@ -3653,9 +3653,6 @@
updateFieldMap();
mDataProvider->updateExtents();
-
- triggerRepaint();
-
QgsDebugMsg( "result:\n " + mCommitErrors.join( "\n " ) );
return success;
@@ -3717,8 +3714,6 @@
// invalidate the cache so the layer updates properly to show its original
// after the rollback
setCacheImage( 0 );
- triggerRepaint();
-
return true;
}
More information about the QGIS-commit
mailing list