comparison src/java/de/intevation/mxd/writer/MapScriptWriter.java @ 204:52b918f958d0

Remove incomplete layer from map.
author raimund renkert <raimund.renkert@intevation.de>
date Thu, 21 Jul 2011 16:17:30 +0200
parents 123fd9887a4f
children 07b991b940ab
comparison
equal deleted inserted replaced
203:123fd9887a4f 204:52b918f958d0
192 for(int i = 0; i < list.getLength(); i++) { 192 for(int i = 0; i < list.getLength(); i++) {
193 Element layerElement = (Element)list.item(i); 193 Element layerElement = (Element)list.item(i);
194 layerObj layer = new layerObj(map); 194 layerObj layer = new layerObj(map);
195 NodeList renderer = layerElement.getElementsByTagName("renderer"); 195 NodeList renderer = layerElement.getElementsByTagName("renderer");
196 if (renderer.getLength() == 0) { 196 if (renderer.getLength() == 0) {
197 map.removeLayer(layer.getIndex());
197 continue; 198 continue;
198 } 199 }
199 200
200 //The layer name. 201 //The layer name.
201 String lname = layerElement.getAttribute("name"); 202 String lname = layerElement.getAttribute("name");
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)