Changeset 5898 in josm for trunk/src/org/openstreetmap/josm/gui/bbox
- Timestamp:
- 2013-04-21T16:27:21+02:00 (12 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/gui/bbox
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/bbox/SlippyMapBBoxChooser.java
r5779 r5898 11 11 import java.awt.Point; 12 12 import java.awt.Rectangle; 13 import java.io.File;14 13 import java.io.IOException; 15 14 import java.util.ArrayList; … … 27 26 import org.openstreetmap.gui.jmapviewer.MapMarkerDot; 28 27 import org.openstreetmap.gui.jmapviewer.MemoryTileCache; 29 import org.openstreetmap.gui.jmapviewer.OsmFileCacheTileLoader;30 28 import org.openstreetmap.gui.jmapviewer.OsmMercator; 31 29 import org.openstreetmap.gui.jmapviewer.OsmTileLoader; 32 30 import org.openstreetmap.gui.jmapviewer.interfaces.MapMarker; 33 import org.openstreetmap.gui.jmapviewer.interfaces.TileLoader;34 import org.openstreetmap.gui.jmapviewer.interfaces.TileLoaderListener;35 31 import org.openstreetmap.gui.jmapviewer.interfaces.TileSource; 36 32 import org.openstreetmap.gui.jmapviewer.tilesources.MapQuestOpenAerialTileSource; … … 39 35 import org.openstreetmap.josm.Main; 40 36 import org.openstreetmap.josm.data.Bounds; 37 import org.openstreetmap.josm.data.Version; 41 38 import org.openstreetmap.josm.data.coor.LatLon; 42 39 import org.openstreetmap.josm.data.imagery.ImageryInfo; … … 171 168 public static final String RESIZE_PROP = SlippyMapBBoxChooser.class.getName() + ".resize"; 172 169 173 private TileLoader cachedLoader;174 private TileLoader uncachedLoader;170 private OsmTileLoader cachedLoader; 171 private OsmTileLoader uncachedLoader; 175 172 176 173 private final SizeButton iSizeButton = new SizeButton(); … … 189 186 190 187 uncachedLoader = new OsmTileLoader(this); 188 uncachedLoader.headers.put("User-Agent", Version.getInstance().getFullAgentString()); 191 189 setZoomContolsVisible(Main.pref.getBoolean("slippy_map_chooser.zoomcontrols",false)); 192 190 setMapMarkerVisible(false); -
trunk/src/org/openstreetmap/josm/gui/bbox/TileSelectionBBoxChooser.java
r5886 r5898 42 42 import org.openstreetmap.gui.jmapviewer.MapMarkerDot; 43 43 import org.openstreetmap.gui.jmapviewer.OsmMercator; 44 import org.openstreetmap.gui.jmapviewer.OsmTileLoader; 44 45 import org.openstreetmap.gui.jmapviewer.interfaces.MapMarker; 46 import org.openstreetmap.gui.jmapviewer.interfaces.TileLoader; 45 47 import org.openstreetmap.josm.data.Bounds; 48 import org.openstreetmap.josm.data.Version; 46 49 import org.openstreetmap.josm.data.coor.LatLon; 47 50 import org.openstreetmap.josm.gui.widgets.AbstractTextComponentValidator; … … 120 123 } 121 124 125 /** 126 * Constructs a new {@code TileSelectionBBoxChooser}. 127 */ 122 128 public TileSelectionBBoxChooser() { 123 129 build(); … … 655 661 public TileBoundsMapView() { 656 662 setBorder(BorderFactory.createLineBorder(Color.DARK_GRAY)); 663 TileLoader loader = tileController.getTileLoader(); 664 if (loader instanceof OsmTileLoader) { 665 ((OsmTileLoader)loader).headers.put("User-Agent", Version.getInstance().getFullAgentString()); 666 } 657 667 } 658 668
Note:
See TracChangeset
for help on using the changeset viewer.