[Schmitzm-commits] r1229 - trunk/src/schmitzm/geotools/gui
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Wed Nov 3 22:08:16 CET 2010
Author: alfonx
Date: 2010-11-03 22:08:15 +0100 (Wed, 03 Nov 2010)
New Revision: 1229
Modified:
trunk/src/schmitzm/geotools/gui/XMapPane.java
Log:
Modified: trunk/src/schmitzm/geotools/gui/XMapPane.java
===================================================================
--- trunk/src/schmitzm/geotools/gui/XMapPane.java 2010-11-03 20:44:16 UTC (rev 1228)
+++ trunk/src/schmitzm/geotools/gui/XMapPane.java 2010-11-03 21:08:15 UTC (rev 1229)
@@ -61,6 +61,7 @@
import org.opengis.display.canvas.RenderingState;
import org.opengis.feature.simple.SimpleFeature;
import org.opengis.feature.simple.SimpleFeatureType;
+import org.opengis.geometry.MismatchedReferenceSystemException;
import org.opengis.referencing.FactoryException;
import org.opengis.referencing.crs.CoordinateReferenceSystem;
import org.opengis.referencing.operation.MathTransform;
@@ -1356,7 +1357,7 @@
public static final String SPECIAL_LINES_LAYER_ID = "SPECIAL_LINES_LAYER_ID";
/**
- * This method ignores sepcial layers like {@link #SPECIAL_LINES_LAYER_ID}
+ * This method ignores special layers like {@link #SPECIAL_LINES_LAYER_ID}
*/
protected ReferencedEnvelope getVisibleLayoutBounds(MapContext context) {
ReferencedEnvelope result = null;
@@ -1406,7 +1407,12 @@
if (result == null) {
result = env;
} else {
- result.expandToInclude(env);
+ try {
+ result.expandToInclude(env.transform(
+ result.getCoordinateReferenceSystem(), true));
+ } catch (Exception e) {
+ LOGGER.error(e);
+ }
}
}
}
More information about the Schmitzm-commits
mailing list