- Timestamp:
- 2016-02-17T23:27:47+01:00 (9 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 2 added
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/ZoomInAction.java
r8510 r9818 47 47 public void actionPerformed(ActionEvent e) { 48 48 if (!Main.isDisplayingMapView()) return; 49 Main.map.mapView.zoom ToFactor(1/Math.sqrt(2));49 Main.map.mapView.zoomIn(); 50 50 } 51 51 -
trunk/src/org/openstreetmap/josm/actions/ZoomOutAction.java
r6380 r9818 33 33 public void actionPerformed(ActionEvent e) { 34 34 if (!Main.isDisplayingMapView()) return; 35 Main.map.mapView.zoom ToFactor(Math.sqrt(2));35 Main.map.mapView.zoomOut(); 36 36 } 37 37 -
trunk/src/org/openstreetmap/josm/data/imagery/WMTSTileSource.java
r9799 r9818 47 47 import org.openstreetmap.josm.data.projection.Projections; 48 48 import org.openstreetmap.josm.gui.ExtendedDialog; 49 import org.openstreetmap.josm.gui.layer.NativeScaleLayer.Scale; 50 import org.openstreetmap.josm.gui.layer.NativeScaleLayer.ScaleList; 49 51 import org.openstreetmap.josm.io.CachedFile; 50 52 import org.openstreetmap.josm.tools.CheckParameterUtil; … … 286 288 } 287 289 288 private Collection<Layer> getCapabilities() throws IOException{290 private Collection<Layer> getCapabilities() { 289 291 XMLInputFactory factory = XMLInputFactory.newFactory(); 290 292 // do not try to load external entities, nor validate the XML … … 709 711 return null; 710 712 } 711 if (zoom < 1) {713 if (zoom < 0) { 712 714 return null; 713 715 } 714 return this.currentTileMatrixSet.tileMatrix.get(zoom - 1);716 return this.currentTileMatrixSet.tileMatrix.get(zoom); 715 717 } 716 718 … … 830 832 public int getMaxZoom() { 831 833 if (this.currentTileMatrixSet != null) { 832 return this.currentTileMatrixSet.tileMatrix.size() ;834 return this.currentTileMatrixSet.tileMatrix.size()-1; 833 835 } 834 836 return 0; … … 911 913 return (int) Math.ceil(Math.abs(max.east() - min.east()) / scale); 912 914 } 915 916 /** 917 * Get native scales of tile source. 918 * @return {@link ScaleList} of native scales 919 */ 920 public ScaleList getNativeScales() { 921 ScaleList scales = new ScaleList(); 922 if (currentTileMatrixSet != null) { 923 for (TileMatrix tileMatrix : currentTileMatrixSet.tileMatrix) { 924 scales.add(new Scale(tileMatrix.scaleDenominator * 0.28e-03)); 925 } 926 } 927 return scales; 928 } 929 913 930 } -
trunk/src/org/openstreetmap/josm/gui/MapMover.java
r8840 r9818 214 214 @Override 215 215 public void mouseWheelMoved(MouseWheelEvent e) { 216 nc.zoom ToFactor(e.getX(), e.getY(), Math.pow(Math.sqrt(2), e.getWheelRotation()));216 nc.zoomManyTimes(e.getX(), e.getY(), e.getWheelRotation()); 217 217 } 218 218 -
trunk/src/org/openstreetmap/josm/gui/MapSlider.java
r8840 r9818 11 11 import javax.swing.event.ChangeListener; 12 12 13 import org.openstreetmap.josm.data.ProjectionBounds;14 13 import org.openstreetmap.josm.gui.help.Helpful; 15 14 16 15 class MapSlider extends JSlider implements PropertyChangeListener, ChangeListener, Helpful { 17 16 17 private static final double zoomStep = 1.1; 18 18 private final MapView mv; 19 19 private boolean preventChange; 20 private int lastValue; 20 21 21 22 MapSlider(MapView mv) { 22 super( 35, 150);23 super(0, 150); 23 24 setOpaque(false); 24 25 this.mv = mv; … … 31 32 @Override 32 33 public void propertyChange(PropertyChangeEvent evt) { 33 if (getModel().getValueIsAdjusting()) return; 34 35 ProjectionBounds world = this.mv.getMaxProjectionBounds(); 36 ProjectionBounds current = this.mv.getProjectionBounds(); 37 38 double cur_e = current.maxEast-current.minEast; 39 double cur_n = current.maxNorth-current.minNorth; 40 double e = world.maxEast-world.minEast; 41 double n = world.maxNorth-world.minNorth; 42 int zoom = 0; 43 44 while (zoom <= 150) { 45 e /= 1.1; 46 n /= 1.1; 47 if (e < cur_e && n < cur_n) { 48 break; 49 } 50 ++zoom; 51 } 34 double maxScale = this.mv.getMaxScale(); 35 int zoom = (int) Math.round(Math.log(maxScale/mv.getScale())/Math.log(zoomStep)); 52 36 preventChange = true; 53 37 setValue(zoom); 38 lastValue = zoom; 54 39 preventChange = false; 55 40 } … … 59 44 if (preventChange) return; 60 45 61 ProjectionBounds world = this.mv.getMaxProjectionBounds(); 62 double fact = Math.pow(1.1, getValue()); 63 double es = world.maxEast-world.minEast; 64 double n = world.maxNorth-world.minNorth; 65 66 this.mv.zoomTo(new ProjectionBounds(this.mv.getCenter(), es/fact, n/fact)); 46 if (!getModel().getValueIsAdjusting() && mv.getNativeScaleLayer() != null) { 47 if (getValue() < lastValue) { 48 mv.zoomOut(); 49 } else if (getValue() > lastValue) { 50 mv.zoomIn(); 51 } 52 } else { 53 double maxScale = this.mv.getMaxScale(); 54 double scale = maxScale/Math.pow(zoomStep, getValue()); 55 double snapped = mv.scaleFloor(scale); 56 mv.zoomTo(this.mv.getCenter(), snapped); 57 } 58 propertyChange(null); 67 59 } 68 60 -
trunk/src/org/openstreetmap/josm/gui/MapView.java
r9623 r9818 60 60 import org.openstreetmap.josm.gui.layer.MapViewPaintable; 61 61 import org.openstreetmap.josm.gui.layer.OsmDataLayer; 62 import org.openstreetmap.josm.gui.layer.NativeScaleLayer; 62 63 import org.openstreetmap.josm.gui.layer.geoimage.GeoImageLayer; 63 64 import org.openstreetmap.josm.gui.layer.markerlayer.MarkerLayer; … … 411 412 if (isOsmDataLayer) { 412 413 ((OsmDataLayer) layer).addLayerStateChangeListener(this); 414 } 415 416 if (layer instanceof NativeScaleLayer) { 417 Main.map.mapView.setNativeScaleLayer((NativeScaleLayer) layer); 413 418 } 414 419 … … 915 920 * 916 921 * @param layer the layer to be activate; must be one of the layers in the list of layers 917 * @throws IllegalArgumentException if layer is not in the lis of layers922 * @throws IllegalArgumentException if layer is not in the list of layers 918 923 */ 919 924 public void setActiveLayer(Layer layer) { -
trunk/src/org/openstreetmap/josm/gui/NavigatableComponent.java
r9634 r9818 45 45 import org.openstreetmap.josm.data.osm.visitor.BoundingXYVisitor; 46 46 import org.openstreetmap.josm.data.osm.visitor.paint.PaintColors; 47 import org.openstreetmap.josm.data.preferences.BooleanProperty; 48 import org.openstreetmap.josm.data.preferences.DoubleProperty; 47 49 import org.openstreetmap.josm.data.preferences.IntegerProperty; 48 50 import org.openstreetmap.josm.data.projection.Projection; … … 50 52 import org.openstreetmap.josm.gui.download.DownloadDialog; 51 53 import org.openstreetmap.josm.gui.help.Helpful; 54 import org.openstreetmap.josm.gui.layer.NativeScaleLayer; 55 import org.openstreetmap.josm.gui.layer.NativeScaleLayer.Scale; 56 import org.openstreetmap.josm.gui.layer.NativeScaleLayer.ScaleList; 52 57 import org.openstreetmap.josm.gui.mappaint.MapPaintStyles; 53 58 import org.openstreetmap.josm.gui.mappaint.mapcss.MapCSSStyleSource; … … 90 95 91 96 public static final IntegerProperty PROP_SNAP_DISTANCE = new IntegerProperty("mappaint.node.snap-distance", 10); 97 public static final DoubleProperty PROP_ZOOM_RATIO = new DoubleProperty("zoom.ratio", 2.0); 98 public static final BooleanProperty PROP_ZOOM_INTERMEDIATE_STEPS = new BooleanProperty("zoom.intermediate-steps", true); 92 99 93 100 public static final String PROPNAME_CENTER = "center"; 94 101 public static final String PROPNAME_SCALE = "scale"; 102 103 /** 104 * The layer which scale is set to. 105 */ 106 private transient NativeScaleLayer nativeScaleLayer; 95 107 96 108 /** … … 144 156 public NavigatableComponent() { 145 157 setLayout(null); 158 PROP_ZOOM_RATIO.get(); // make sure it is available in preferences 159 } 160 161 /** 162 * Choose a layer that scale will be snap to its native scales. 163 * @param nativeScaleLayer layer to which scale will be snapped 164 */ 165 public void setNativeScaleLayer(NativeScaleLayer nativeScaleLayer) { 166 this.nativeScaleLayer = nativeScaleLayer; 167 zoomTo(center, scaleRound(scale)); 168 repaint(); 169 } 170 171 /** 172 * Replies the layer which scale is set to. 173 * @return the current scale layer (may be null) 174 */ 175 public NativeScaleLayer getNativeScaleLayer() { 176 return nativeScaleLayer; 177 } 178 179 /** 180 * Get a new scale that is zoomed in from previous scale 181 * and snapped to selected native scale layer. 182 * @return new scale 183 */ 184 public double scaleZoomIn() { 185 return scaleZoomManyTimes(-1); 186 } 187 188 /** 189 * Get a new scale that is zoomed out from previous scale 190 * and snapped to selected native scale layer. 191 * @return new scale 192 */ 193 public double scaleZoomOut() { 194 return scaleZoomManyTimes(1); 195 } 196 197 /** 198 * Get a new scale that is zoomed in/out a number of times 199 * from previous scale and snapped to selected native scale layer. 200 * @param times count of zoom operations, negative means zoom in 201 * @return new scale 202 */ 203 public double scaleZoomManyTimes(int times) { 204 if (nativeScaleLayer != null) { 205 ScaleList scaleList = nativeScaleLayer.getNativeScales(); 206 if (PROP_ZOOM_INTERMEDIATE_STEPS.get()) { 207 scaleList = scaleList.withIntermediateSteps(PROP_ZOOM_RATIO.get()); 208 } 209 Scale scale = scaleList.scaleZoomTimes(getScale(), PROP_ZOOM_RATIO.get(), times); 210 return scale.scale; 211 } else { 212 return getScale() * Math.pow(PROP_ZOOM_RATIO.get(), times); 213 } 214 } 215 216 /** 217 * Get a scale snapped to native resolutions, use round method. 218 * It gives nearest step from scale list. 219 * Use round method. 220 * @param scale to snap 221 * @return snapped scale 222 */ 223 public double scaleRound(double scale) { 224 return scaleSnap(scale, false); 225 } 226 227 /** 228 * Get a scale snapped to native resolutions. 229 * It gives nearest lower step from scale list, usable to fit objects. 230 * @param scale to snap 231 * @return snapped scale 232 */ 233 public double scaleFloor(double scale) { 234 return scaleSnap(scale, true); 235 } 236 237 /** 238 * Get a scale snapped to native resolutions. 239 * It gives nearest lower step from scale list, usable to fit objects. 240 * @param scale to snap 241 * @param floor use floor instead of round, set true when fitting view to objects 242 * @return new scale 243 */ 244 public double scaleSnap(double scale, boolean floor) { 245 if (nativeScaleLayer != null) { 246 ScaleList scaleList = nativeScaleLayer.getNativeScales(); 247 return scaleList.getSnapScale(scale, PROP_ZOOM_RATIO.get(), floor).scale; 248 } else { 249 return scale; 250 } 251 } 252 253 /** 254 * Zoom in current view. Use configured zoom step and scaling settings. 255 */ 256 public void zoomIn() { 257 zoomTo(center, scaleZoomIn()); 258 } 259 260 /** 261 * Zoom out current view. Use configured zoom step and scaling settings. 262 */ 263 public void zoomOut() { 264 zoomTo(center, scaleZoomOut()); 146 265 } 147 266 … … 435 554 } 436 555 } 556 557 // snap scale to imagery if needed 558 scale = scaleRound(scale); 437 559 438 560 if (!newCenter.equals(center) || !Utils.equalsEpsilon(scale, newScale)) { … … 517 639 } 518 640 641 public void zoomManyTimes(double x, double y, int times) { 642 double oldScale = scale; 643 double newScale = scaleZoomManyTimes(times); 644 zoomToFactor(x, y, newScale / oldScale); 645 } 646 519 647 public void zoomToFactor(double x, double y, double factor) { 520 648 double newScale = scale*factor; … … 550 678 double newScale = Math.max(scaleX, scaleY); 551 679 680 newScale = scaleFloor(newScale); 552 681 zoomTo(box.getCenter(), newScale); 553 682 } … … 1505 1634 repaint(); 1506 1635 } 1636 1637 /** 1638 * Get a max scale for projection that describes world in 256 pixels 1639 * @return max scale 1640 */ 1641 public double getMaxScale() { 1642 ProjectionBounds world = getMaxProjectionBounds(); 1643 return Math.max( 1644 world.maxNorth-world.minNorth, 1645 world.maxEast-world.minEast 1646 )/256; 1647 } 1507 1648 } -
trunk/src/org/openstreetmap/josm/gui/dialogs/LayerListDialog.java
r9510 r9818 60 60 import org.openstreetmap.josm.gui.layer.Layer; 61 61 import org.openstreetmap.josm.gui.layer.Layer.LayerAction; 62 import org.openstreetmap.josm.gui.layer.NativeScaleLayer; 62 63 import org.openstreetmap.josm.gui.layer.OsmDataLayer; 63 64 import org.openstreetmap.josm.gui.util.GuiHelper; … … 188 189 layerList.getColumnModel().getColumn(0).setPreferredWidth(12); 189 190 layerList.getColumnModel().getColumn(0).setResizable(false); 190 layerList.getColumnModel().getColumn(1).setCellRenderer(new LayerVisibleCellRenderer()); 191 layerList.getColumnModel().getColumn(1).setCellEditor(new LayerVisibleCellEditor(new LayerVisibleCheckBox())); 192 layerList.getColumnModel().getColumn(1).setMaxWidth(16); 193 layerList.getColumnModel().getColumn(1).setPreferredWidth(16); 191 192 layerList.getColumnModel().getColumn(1).setCellRenderer(new NativeScaleLayerCellRenderer()); 193 layerList.getColumnModel().getColumn(1).setCellEditor(new DefaultCellEditor(new NativeScaleLayerCheckBox())); 194 layerList.getColumnModel().getColumn(1).setMaxWidth(12); 195 layerList.getColumnModel().getColumn(1).setPreferredWidth(12); 194 196 layerList.getColumnModel().getColumn(1).setResizable(false); 195 layerList.getColumnModel().getColumn(2).setCellRenderer(new LayerNameCellRenderer()); 196 layerList.getColumnModel().getColumn(2).setCellEditor(new LayerNameCellEditor(new DisableShortcutsOnFocusGainedTextField())); 197 198 layerList.getColumnModel().getColumn(2).setCellRenderer(new LayerVisibleCellRenderer()); 199 layerList.getColumnModel().getColumn(2).setCellEditor(new LayerVisibleCellEditor(new LayerVisibleCheckBox())); 200 layerList.getColumnModel().getColumn(2).setMaxWidth(16); 201 layerList.getColumnModel().getColumn(2).setPreferredWidth(16); 202 layerList.getColumnModel().getColumn(2).setResizable(false); 203 204 layerList.getColumnModel().getColumn(3).setCellRenderer(new LayerNameCellRenderer()); 205 layerList.getColumnModel().getColumn(3).setCellEditor(new LayerNameCellEditor(new DisableShortcutsOnFocusGainedTextField())); 197 206 // Disable some default JTable shortcuts to use JOSM ones (see #5678, #10458) 198 207 for (KeyStroke ks : new KeyStroke[] { … … 1026 1035 } 1027 1036 1037 private static class NativeScaleLayerCheckBox extends JCheckBox { 1038 NativeScaleLayerCheckBox() { 1039 setHorizontalAlignment(javax.swing.SwingConstants.CENTER); 1040 ImageIcon blank = ImageProvider.get("dialogs/layerlist", "blank"); 1041 ImageIcon active = ImageProvider.get("dialogs/layerlist", "scale"); 1042 setIcon(blank); 1043 setSelectedIcon(active); 1044 } 1045 } 1046 1028 1047 private static class ActiveLayerCellRenderer implements TableCellRenderer { 1029 1048 private final JCheckBox cb; … … 1038 1057 @Override 1039 1058 public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) { 1040 boolean active = 1059 boolean active = value != null && (Boolean) value; 1041 1060 cb.setSelected(active); 1042 1061 cb.setToolTipText(active ? tr("this layer is the active layer") : tr("this layer is not currently active (click to activate)")); … … 1075 1094 public Component getTableCellEditorComponent(JTable table, Object value, boolean isSelected, int row, int column) { 1076 1095 cb.updateStatus((Layer) value); 1096 return cb; 1097 } 1098 } 1099 1100 private static class NativeScaleLayerCellRenderer implements TableCellRenderer { 1101 private final JCheckBox cb; 1102 1103 /** 1104 * Constructs a new {@code ActiveLayerCellRenderer}. 1105 */ 1106 NativeScaleLayerCellRenderer() { 1107 cb = new NativeScaleLayerCheckBox(); 1108 } 1109 1110 @Override 1111 public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) { 1112 Layer layer = (Layer) value; 1113 if (layer instanceof NativeScaleLayer) { 1114 boolean active = layer != null && layer == Main.map.mapView.getNativeScaleLayer(); 1115 cb.setSelected(active); 1116 cb.setToolTipText(active 1117 ? tr("scale follows native resolution of this layer") 1118 : tr("scale follows native resolution of another layer (click to set this layer)") 1119 ); 1120 } else { 1121 cb.setSelected(false); 1122 cb.setToolTipText(tr("this layer has no native resolution")); 1123 } 1077 1124 return cb; 1078 1125 } … … 1550 1597 } 1551 1598 1599 /** 1600 * Replies the scale layer. null, if no active layer is available 1601 * 1602 * @return the scale layer. null, if no active layer is available 1603 */ 1604 protected NativeScaleLayer getNativeScaleLayer() { 1605 if (!Main.isDisplayingMapView()) return null; 1606 return Main.map.mapView.getNativeScaleLayer(); 1607 } 1608 1552 1609 /* ------------------------------------------------------------------------------ */ 1553 1610 /* Interface TableModel */ … … 1563 1620 @Override 1564 1621 public int getColumnCount() { 1565 return 3;1622 return 4; 1566 1623 } 1567 1624 … … 1574 1631 case 1: return layers.get(row); 1575 1632 case 2: return layers.get(row); 1633 case 3: return layers.get(row); 1576 1634 default: throw new RuntimeException(); 1577 1635 } … … 1598 1656 break; 1599 1657 case 1: 1658 if (Main.map.mapView.getNativeScaleLayer() == l) { 1659 Main.map.mapView.setNativeScaleLayer(null); 1660 } else if (l instanceof NativeScaleLayer) { 1661 Main.map.mapView.setNativeScaleLayer((NativeScaleLayer) l); 1662 } 1663 break; 1664 case 2: 1600 1665 l.setVisible((Boolean) value); 1601 1666 break; 1602 case 2:1667 case 3: 1603 1668 l.rename((String) value); 1604 1669 break; -
trunk/src/org/openstreetmap/josm/gui/layer/TMSLayer.java
r9731 r9818 5 5 6 6 import org.apache.commons.jcs.access.CacheAccess; 7 import org.openstreetmap.gui.jmapviewer.OsmMercator; 7 8 import org.openstreetmap.gui.jmapviewer.interfaces.TileLoader; 8 9 import org.openstreetmap.gui.jmapviewer.tilesources.AbstractTMSTileSource; … … 29 30 * 30 31 */ 31 public class TMSLayer extends AbstractCachedTileSourceLayer {32 public class TMSLayer extends AbstractCachedTileSourceLayer implements NativeScaleLayer { 32 33 private static final String CACHE_REGION_NAME = "TMS"; 33 34 … … 145 146 return AbstractCachedTileSourceLayer.getCache(CACHE_REGION_NAME); 146 147 } 148 149 @Override 150 public ScaleList getNativeScales() { 151 ScaleList scales = new ScaleList(); 152 for (int zoom = info.getMinZoom(); zoom <= info.getMaxZoom(); zoom++) { 153 double scale = OsmMercator.EARTH_RADIUS * Math.PI * 2 / Math.pow(2, zoom) / OsmMercator.DEFAUL_TILE_SIZE; 154 scales.add(new Scale(scale)); 155 } 156 return scales; 157 } 147 158 } -
trunk/src/org/openstreetmap/josm/gui/layer/WMTSLayer.java
r9430 r9818 6 6 7 7 import org.apache.commons.jcs.access.CacheAccess; 8 import org.openstreetmap.gui.jmapviewer.TileXY;9 import org.openstreetmap.gui.jmapviewer.interfaces.ICoordinate;10 8 import org.openstreetmap.gui.jmapviewer.interfaces.TileLoader; 11 9 import org.openstreetmap.gui.jmapviewer.tilesources.AbstractTMSTileSource; 12 10 import org.openstreetmap.josm.Main; 13 11 import org.openstreetmap.josm.data.cache.BufferedImageCacheEntry; 14 import org.openstreetmap.josm.data.coor.LatLon;15 12 import org.openstreetmap.josm.data.imagery.ImageryInfo; 16 13 import org.openstreetmap.josm.data.imagery.ImageryInfo.ImageryType; … … 19 16 import org.openstreetmap.josm.data.preferences.BooleanProperty; 20 17 import org.openstreetmap.josm.data.projection.Projection; 21 import org.openstreetmap.josm.gui.MapView;22 18 23 19 /** … … 28 24 * http://www.opengeospatial.org/standards/wmts 29 25 * 30 * @author Wiktor Niesiob ędzki26 * @author Wiktor NiesiobÄ™dzki 31 27 * 32 28 */ 33 public class WMTSLayer extends AbstractCachedTileSourceLayer {29 public class WMTSLayer extends AbstractCachedTileSourceLayer implements NativeScaleLayer { 34 30 /** 35 31 * default setting of autozoom per layer … … 63 59 } 64 60 65 /** 66 * @param zoom level of the tile 67 * @return how many pixels of the screen occupies one pixel of the tile 68 */ 69 private double getTileToScreenRatio(int zoom) { 70 MapView mv = Main.map.mapView; 71 LatLon topLeft = mv.getLatLon(0, 0); 72 LatLon botLeft = mv.getLatLon(0, tileSource.getTileSize()); 73 74 TileXY topLeftTile = tileSource.latLonToTileXY(topLeft.toCoordinate(), zoom); 75 76 ICoordinate north = tileSource.tileXYToLatLon(topLeftTile.getXIndex(), topLeftTile.getYIndex(), zoom); 77 ICoordinate south = tileSource.tileXYToLatLon(topLeftTile.getXIndex(), topLeftTile.getYIndex() + 1, zoom); 78 79 return Math.abs((north.getLat() - south.getLat()) / (topLeft.lat() - botLeft.lat())); 61 @Override 62 protected int getBestZoom() { 63 if (!Main.isDisplayingMapView()) return 0; 64 ScaleList scaleList = getNativeScales(); 65 for (int i = scaleList.size()-1; i >= 0; i--) { 66 Scale scale = scaleList.get(i); 67 if (scale.scale >= Main.map.mapView.getScale()) { 68 return i; 69 } 70 } 71 return 0; 80 72 } 81 73 82 74 @Override 83 protected int getBestZoom() { 84 if (!Main.isDisplayingMapView()) return 1; 75 protected int getMaxZoomLvl() { 76 return getNativeScales().size()-1; 77 } 85 78 86 for (int i = getMinZoomLvl() + 1; i <= getMaxZoomLvl(); i++) { 87 double ret = getTileToScreenRatio(i); 88 if (ret < 1) { 89 return i - 1; 90 } 91 } 92 return getMaxZoomLvl(); 79 @Override 80 protected int getMinZoomLvl() { 81 return 0; 93 82 } 94 83 … … 130 119 return AbstractCachedTileSourceLayer.getCache(CACHE_REGION_NAME); 131 120 } 121 122 @Override 123 public ScaleList getNativeScales() { 124 return ((WMTSTileSource) tileSource).getNativeScales(); 125 } 132 126 }
Note:
See TracChangeset
for help on using the changeset viewer.