s/getTileBounds/getExtentTileBounds/
This commit is contained in:
+1
-1
@@ -170,7 +170,7 @@ TileGrid
|
|||||||
corner TOP_LEFT | BOTTOM_LEFT
|
corner TOP_LEFT | BOTTOM_LEFT
|
||||||
origin(s) Coord|Array.<Coord>
|
origin(s) Coord|Array.<Coord>
|
||||||
tileSize goog.math.Size
|
tileSize goog.math.Size
|
||||||
getTileBounds(z, extent) -> TileBounds
|
getExtentTileBounds(z, extent) -> TileBounds
|
||||||
getTileCoordCenter(tileCoord) -> goog.math.Coordinate
|
getTileCoordCenter(tileCoord) -> goog.math.Coordinate
|
||||||
getTileCoord(coordinate) -> TileCoord
|
getTileCoord(coordinate) -> TileCoord
|
||||||
getTileCoordExtent(tileCoord) -> ol.Extent
|
getTileCoordExtent(tileCoord) -> ol.Extent
|
||||||
|
|||||||
+3
-3
@@ -134,7 +134,7 @@ ol.TileGrid.prototype.getResolutions = function() {
|
|||||||
* @param {ol.Extent} extent Extent.
|
* @param {ol.Extent} extent Extent.
|
||||||
* @return {ol.TileBounds} Tile bounds.
|
* @return {ol.TileBounds} Tile bounds.
|
||||||
*/
|
*/
|
||||||
ol.TileGrid.prototype.getTileBounds = function(z, extent) {
|
ol.TileGrid.prototype.getExtentTileBounds = function(z, extent) {
|
||||||
var topRight = new goog.math.Coordinate(extent.right, extent.top);
|
var topRight = new goog.math.Coordinate(extent.right, extent.top);
|
||||||
var bottomLeft = new goog.math.Coordinate(extent.left, extent.bottom);
|
var bottomLeft = new goog.math.Coordinate(extent.left, extent.bottom);
|
||||||
return ol.TileBounds.boundingTileBounds(
|
return ol.TileBounds.boundingTileBounds(
|
||||||
@@ -235,10 +235,10 @@ ol.TileGrid.prototype.getTileResolution = function(tileCoord) {
|
|||||||
* @param {function(number, ol.TileBounds): boolean} callback Callback.
|
* @param {function(number, ol.TileBounds): boolean} callback Callback.
|
||||||
*/
|
*/
|
||||||
ol.TileGrid.prototype.yieldTileCoordParents = function(tileCoord, callback) {
|
ol.TileGrid.prototype.yieldTileCoordParents = function(tileCoord, callback) {
|
||||||
var extent = this.getTileCoordExtent(tileCoord);
|
var tileCoordExtent = this.getTileCoordExtent(tileCoord);
|
||||||
var z = tileCoord.z - 1;
|
var z = tileCoord.z - 1;
|
||||||
while (z >= 0) {
|
while (z >= 0) {
|
||||||
if (callback(z, this.getTileBounds(z, extent))) {
|
if (callback(z, this.getExtentTileBounds(z, tileCoordExtent))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
--z;
|
--z;
|
||||||
|
|||||||
Reference in New Issue
Block a user