Remove static members from ImageMapGuide

This commit is contained in:
Tim Schaub
2018-02-25 08:24:24 -07:00
parent 42cf5f8511
commit 12eccdc52d

View File

@@ -173,7 +173,7 @@ ImageMapGuide.prototype.getImageLoadFunction = function() {
* @param {number} dpi The display resolution.
* @return {number} The computed map scale.
*/
ImageMapGuide.getScale = function(extent, size, metersPerUnit, dpi) {
function getScale(extent, size, metersPerUnit, dpi) {
const mcsW = getWidth(extent);
const mcsH = getHeight(extent);
const devW = size[0];
@@ -184,7 +184,7 @@ ImageMapGuide.getScale = function(extent, size, metersPerUnit, dpi) {
} else {
return mcsH * metersPerUnit / (devH * mpp); // height limited
}
};
}
/**
@@ -207,7 +207,7 @@ ImageMapGuide.prototype.updateParams = function(params) {
* @return {string} The mapagent map image request URL.
*/
ImageMapGuide.prototype.getUrl = function(baseUrl, params, extent, size, projection) {
const scale = ImageMapGuide.getScale(extent, size,
const scale = getScale(extent, size,
this.metersPerUnit_, this.displayDpi_);
const center = getCenter(extent);
const baseParams = {