[QGIS Commit] r11406 - trunk/qgis/src/core

svn_qgis at osgeo.org svn_qgis at osgeo.org
Mon Aug 17 06:20:28 EDT 2009


Author: homann
Date: 2009-08-17 06:20:27 -0400 (Mon, 17 Aug 2009)
New Revision: 11406

Modified:
   trunk/qgis/src/core/qgsvectorlayer.cpp
Log:
Always set coordinate system, independent of any symbology style settings. Fixes #1604

Modified: trunk/qgis/src/core/qgsvectorlayer.cpp
===================================================================
--- trunk/qgis/src/core/qgsvectorlayer.cpp	2009-08-17 09:52:12 UTC (rev 11405)
+++ trunk/qgis/src/core/qgsvectorlayer.cpp	2009-08-17 10:20:27 UTC (rev 11406)
@@ -115,6 +115,9 @@
   }
   if ( mValid )
   {
+    // Always set crs
+    setCoordinateSystem();
+
     // check if there is a default style / propertysheet defined
     // for this layer and if so apply it
     //
@@ -124,7 +127,6 @@
       loadDefaultStyle( defaultLoadedFlag );
       if ( !defaultLoadedFlag )
       {
-        setCoordinateSystem();
         // add single symbol renderer as default
         QgsSingleSymbolRenderer *renderer = new QgsSingleSymbolRenderer( geometryType() );
         setRenderer( renderer );
@@ -132,7 +134,6 @@
     }
     else  // Otherwise use some very basic defaults
     {
-      setCoordinateSystem();
       // add single symbol renderer as default
       QgsSingleSymbolRenderer *renderer = new QgsSingleSymbolRenderer( geometryType() );
       setRenderer( renderer );



More information about the QGIS-commit mailing list