Revision 11333

View differences:

branches/v10/applications/appgvSIG/src/com/iver/cit/gvsig/project/Project.java
117 117
public class Project implements Serializable, PropertyChangeListener {
118 118
	public static String VERSION = Version.format();
119 119

  
120
	static private IProjection defaultProjection = CRSFactory
121
			.getCRS("EPSG:23030");
120
	static private IProjection defaultProjection = null;
122 121

  
122
	static private IProjection defaultFactoryProjection = CRSFactory
123
	.getCRS("EPSG:23030");
124

  
123 125
	/*
124 126
	 * distiguishing between a static field "defaultSelectionColor" and a
125 127
	 * selectionColor field will allow to define default color in a multiple
......
1349 1351
	}
1350 1352

  
1351 1353
	public static IProjection getDefaultProjection() {
1354
		if (defaultProjection == null){
1355
			XMLEntity xml = PluginServices.getPluginServices("com.iver.cit.gvsig")
1356
			.getPersistentXML();
1357
	
1358
			// Default Projection
1359
			String projCode = null; 
1360
			if (xml.contains("DefaultProjection")) {
1361
				projCode = xml.getStringProperty("DefaultProjection");
1362
				Project.setDefaultProjection(CRSFactory.getCRS(projCode));
1363
			} else {
1364
				Project.setDefaultProjection(defaultFactoryProjection);
1365
			}
1366
			
1367
		}
1352 1368
		return Project.defaultProjection;
1353 1369
	}
1354 1370

  

Also available in: Unified diff