removing the restrictedMinZoom property, and allow for restricting zoom levels with maxResolution and numZoomLevels. Thanks tschaub for the doc, test and examples improvements. r=tschaub (see #3338)
git-svn-id: http://svn.openlayers.org/trunk/openlayers@12106 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -1927,8 +1927,8 @@ OpenLayers.Map = OpenLayers.Class({
|
||||
*/
|
||||
isValidZoomLevel: function(zoomLevel) {
|
||||
return ( (zoomLevel != null) &&
|
||||
(zoomLevel >= this.getRestrictedMinZoom()) &&
|
||||
(zoomLevel < this.getNumZoomLevels()) );
|
||||
(zoomLevel >= 0) &&
|
||||
(zoomLevel < this.getNumZoomLevels()) );
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -2031,20 +2031,6 @@ OpenLayers.Map = OpenLayers.Class({
|
||||
return maxExtent;
|
||||
},
|
||||
|
||||
/**
|
||||
* Method: getRestricteMinZoom
|
||||
*
|
||||
* Returns:
|
||||
* {Integer} the minimum zoom level allowed for the current baseLayer.
|
||||
*/
|
||||
getRestrictedMinZoom: function() {
|
||||
var minZoom = null;
|
||||
if (this.baseLayer != null) {
|
||||
minZoom = this.baseLayer.restrictedMinZoom;
|
||||
}
|
||||
return minZoom;
|
||||
},
|
||||
|
||||
/**
|
||||
* APIMethod: getNumZoomLevels
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user