Changeset 27990 in osm
- Timestamp:
- 2012-03-05T20:07:02+01:00 (13 years ago)
- Location:
- applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/Demo.java
r26701 r27990 82 82 }); 83 83 JComboBox tileSourceSelector = new JComboBox(new TileSource[] { new OsmTileSource.Mapnik(), 84 new OsmTileSource. TilesAtHome(), new OsmTileSource.CycleMap(), new BingAerialTileSource() });84 new OsmTileSource.CycleMap(), new BingAerialTileSource() }); 85 85 tileSourceSelector.addItemListener(new ItemListener() { 86 86 public void itemStateChanged(ItemEvent e) { -
applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/tilesources/OsmTileSource.java
r26249 r27990 4 4 5 5 public static final String MAP_MAPNIK = "http://tile.openstreetmap.org"; 6 public static final String MAP_OSMA = "http://tah.openstreetmap.org/Tiles";7 6 8 7 public static class Mapnik extends AbstractOsmTileSource { … … 44 43 } 45 44 } 46 47 public static abstract class OsmaSource extends AbstractOsmTileSource {48 String osmaSuffix;49 50 public OsmaSource(String name, String osmaSuffix) {51 super(name, MAP_OSMA);52 this.osmaSuffix = osmaSuffix;53 }54 55 @Override56 public int getMaxZoom() {57 return 17;58 }59 60 @Override61 public String getBaseUrl() {62 return MAP_OSMA + "/" + osmaSuffix;63 }64 65 public TileUpdate getTileUpdate() {66 return TileUpdate.IfModifiedSince;67 }68 }69 70 public static class TilesAtHome extends OsmaSource {71 public TilesAtHome() {72 super("TilesAtHome", "tile");73 }74 }75 76 public static class Maplint extends OsmaSource {77 public Maplint() {78 super("Maplint", "maplint");79 }80 }81 45 }
Note:
See TracChangeset
for help on using the changeset viewer.