Revision 46306 trunk/org.gvsig.desktop/org.gvsig.desktop.compat.cdc/org.gvsig.fmap.mapcontext/org.gvsig.fmap.mapcontext.api/src/main/java/org/gvsig/fmap/mapcontext/layers/vectorial/FLyrVect.java
FLyrVect.java | ||
---|---|---|
239 | 239 |
|
240 | 240 |
// Esto es para cuando se crea una capa nueva con el fullExtent de ancho |
241 | 241 |
// y alto 0. |
242 |
if (rAux == null || rAux.isEmpty() || rAux.getMaximum(0) - rAux.getMinimum(0) == 0 |
|
243 |
&& rAux.getMaximum(1) - rAux.getMinimum(1) == 0) { |
|
244 |
try { |
|
245 |
rAux |
|
246 |
= geomManager.createEnvelope(0, 0, 90, 90, SUBTYPES.GEOM2D); |
|
247 |
} catch (CreateEnvelopeException e) { |
|
248 |
logger.error("Error creating the envelope", e); |
|
249 |
e.printStackTrace(); |
|
250 |
} |
|
242 |
if (rAux == null || rAux.isEmpty() ) { |
|
243 |
// || rAux.isCollapsed(Geometry.SUBTYPES.GEOM2D) ) { |
|
244 |
// try { |
|
245 |
// rAux |
|
246 |
// = geomManager.createEnvelope(0, 0, 90, 90, SUBTYPES.GEOM2D); |
|
247 |
// } catch (CreateEnvelopeException e) { |
|
248 |
// logger.error("Error creating the envelope", e); |
|
249 |
// e.printStackTrace(); |
|
250 |
// } |
|
251 |
return rAux; |
|
251 | 252 |
} |
252 | 253 |
// Si existe reproyecci?n, reproyectar el extent |
253 | 254 |
ICoordTrans ct = getCoordTrans(); |
254 | 255 |
if (ct != null) { |
255 |
boolean originalEnvelopeIsEmpty = rAux.isEmpty(); |
|
256 |
// boolean originalEnvelopeIsEmpty = rAux.isEmpty();
|
|
256 | 257 |
rAux = rAux.convert(ct); |
257 |
if (!originalEnvelopeIsEmpty && rAux.isEmpty()) { |
|
258 |
// if (!originalEnvelopeIsEmpty && rAux.isEmpty()) { |
|
259 |
if (rAux==null || rAux.isEmpty() ) { |
|
258 | 260 |
try { |
259 | 261 |
this.setAvailable(false); |
260 | 262 |
throw new EnvelopeCantBeInitializedException(); |
Also available in: Unified diff