@@ -757,6 +757,12 @@ void QgsVectorLayer::drawRendererV2( QgsRenderContext& rendererContext, bool lab
757
757
// render feature
758
758
mRendererV2 ->renderFeature ( fet, rendererContext, -1 , sel, drawMarker );
759
759
760
+ if ( mEditable )
761
+ {
762
+ // Cache this for the use of (e.g.) modifying the feature's uncommitted geometry.
763
+ mCachedGeometries [fet.id ()] = *fet.geometry ();
764
+ }
765
+
760
766
// labeling - register feature
761
767
if ( mRendererV2 ->symbolForFeature ( fet ) != NULL )
762
768
{
@@ -769,12 +775,6 @@ void QgsVectorLayer::drawRendererV2( QgsRenderContext& rendererContext, bool lab
769
775
rendererContext.labelingEngine ()->registerDiagramFeature ( this , fet, rendererContext );
770
776
}
771
777
}
772
-
773
- if ( mEditable )
774
- {
775
- // Cache this for the use of (e.g.) modifying the feature's uncommitted geometry.
776
- mCachedGeometries [fet.id ()] = *fet.geometry ();
777
- }
778
778
}
779
779
catch ( const QgsCsException &cse )
780
780
{
@@ -834,6 +834,12 @@ void QgsVectorLayer::drawRendererV2Levels( QgsRenderContext& rendererContext, bo
834
834
}
835
835
features[sym].append ( fet );
836
836
837
+ if ( mEditable )
838
+ {
839
+ // Cache this for the use of (e.g.) modifying the feature's uncommitted geometry.
840
+ mCachedGeometries [fet.id ()] = *fet.geometry ();
841
+ }
842
+
837
843
if ( mRendererV2 ->symbolForFeature ( fet ) != NULL )
838
844
{
839
845
if ( labeling )
@@ -846,11 +852,6 @@ void QgsVectorLayer::drawRendererV2Levels( QgsRenderContext& rendererContext, bo
846
852
}
847
853
}
848
854
849
- if ( mEditable )
850
- {
851
- // Cache this for the use of (e.g.) modifying the feature's uncommitted geometry.
852
- mCachedGeometries [fet.id ()] = *fet.geometry ();
853
- }
854
855
#ifndef Q_WS_MAC
855
856
++featureCount;
856
857
#endif // Q_WS_MAC
0 commit comments