File tree Expand file tree Collapse file tree 2 files changed +9
-5
lines changed Expand file tree Collapse file tree 2 files changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -340,7 +340,16 @@ void QgsLegendLayer::updateIcon()
340
340
// TODO: projection error icon?
341
341
342
342
QIcon theIcon ( newIcon );
343
+ QgsLegend* l = legend ();
344
+ if ( l )
345
+ {
346
+ l->blockSignals ( true ); // prevent unnecessary canvas redraw
347
+ }
343
348
setIcon ( 0 , theIcon );
349
+ if ( l )
350
+ {
351
+ l->blockSignals ( false );
352
+ }
344
353
}
345
354
346
355
QPixmap QgsLegendLayer::getOriginalPixmap ()
Original file line number Diff line number Diff line change @@ -3653,9 +3653,6 @@ bool QgsVectorLayer::commitChanges()
3653
3653
3654
3654
updateFieldMap ();
3655
3655
mDataProvider ->updateExtents ();
3656
-
3657
- triggerRepaint ();
3658
-
3659
3656
QgsDebugMsg ( " result:\n " + mCommitErrors .join ( " \n " ) );
3660
3657
3661
3658
return success;
@@ -3717,8 +3714,6 @@ bool QgsVectorLayer::rollBack()
3717
3714
// invalidate the cache so the layer updates properly to show its original
3718
3715
// after the rollback
3719
3716
setCacheImage ( 0 );
3720
- triggerRepaint ();
3721
-
3722
3717
return true ;
3723
3718
}
3724
3719
You can’t perform that action at this time.
0 commit comments