Changeset 8526 in josm for trunk/src/org/openstreetmap/josm/io/session/ImagerySessionImporter.java
- Timestamp:
- 2015-06-24T20:57:43+02:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/io/session/ImagerySessionImporter.java
r8510 r8526 11 11 import org.openstreetmap.josm.data.imagery.ImageryInfo; 12 12 import org.openstreetmap.josm.data.imagery.ImageryInfo.ImageryPreferenceEntry; 13 import org.openstreetmap.josm.gui.layer.AbstractTileSourceLayer; 13 14 import org.openstreetmap.josm.gui.layer.ImageryLayer; 14 15 import org.openstreetmap.josm.gui.layer.Layer; 15 import org.openstreetmap.josm.gui.layer.WMSLayer;16 16 import org.openstreetmap.josm.gui.progress.ProgressMonitor; 17 17 import org.openstreetmap.josm.io.IllegalDataException; … … 46 46 ImageryInfo i = new ImageryInfo(prefEntry); 47 47 ImageryLayer layer = ImageryLayer.create(i); 48 if (layer instanceof WMSLayer) { 49 WMSLayer wms = (WMSLayer) layer; 50 String autoDownload = attributes.get("automatic-downloading"); 51 if (autoDownload != null) { 52 wms.setAutoDownload(Boolean.parseBoolean(autoDownload)); 48 if (layer instanceof AbstractTileSourceLayer) { 49 AbstractTileSourceLayer tsLayer = (AbstractTileSourceLayer) layer; 50 if (attributes.containsKey("automatic-downloading")) { 51 tsLayer.autoLoad = new Boolean(attributes.get("automatic-downloading")).booleanValue(); 53 52 } 54 String autoResolution = attributes.get("automatically-change-resolution"); 55 if (autoResolution != null) { 56 wms.setAutoResolution(Boolean.parseBoolean(autoResolution)); 53 54 if (attributes.containsKey("automatically-change-resolution")) { 55 tsLayer.autoZoom = new Boolean(attributes.get("automatically-change-resolution")).booleanValue(); 56 } 57 58 if (attributes.containsKey("show-errors")) { 59 tsLayer.showErrors = new Boolean(attributes.get("show-errors")).booleanValue(); 57 60 } 58 61 }
Note:
See TracChangeset
for help on using the changeset viewer.