Giving a tile bounds.
This commit is contained in:
@@ -1,11 +1,14 @@
|
||||
goog.provide('ol.Tile');
|
||||
|
||||
goog.require('ol.Bounds');
|
||||
|
||||
/**
|
||||
* The Tile class.
|
||||
* @constructor
|
||||
* @param {string} url
|
||||
* @param {ol.Bounds} bounds
|
||||
*/
|
||||
ol.Tile = function(url) {
|
||||
ol.Tile = function(url, bounds) {
|
||||
|
||||
/**
|
||||
* @private
|
||||
@@ -13,6 +16,12 @@ ol.Tile = function(url) {
|
||||
*/
|
||||
this.url_ = url;
|
||||
|
||||
/**
|
||||
* @private
|
||||
* @type {ol.Bounds}
|
||||
*/
|
||||
this.bounds_ = bounds;
|
||||
|
||||
/**
|
||||
* @private
|
||||
* @type {Element}
|
||||
@@ -35,6 +44,14 @@ ol.Tile.prototype.getUrl = function() {
|
||||
return this.url_;
|
||||
};
|
||||
|
||||
/**
|
||||
* Get the tile bounds.
|
||||
* @return {ol.Bounds}
|
||||
*/
|
||||
ol.Tile.prototype.getBounds = function() {
|
||||
return this.bounds_;
|
||||
};
|
||||
|
||||
/**
|
||||
* Get the tile image.
|
||||
* @return {Element}
|
||||
|
||||
Reference in New Issue
Block a user