X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/4368ba9f117651cdfbf1e21225a518a566130a2f..da788000609800969da1b1f2a4032a0229ab94ee:/app/assets/javascripts/openlayers.js.erb diff --git a/app/assets/javascripts/openlayers.js.erb b/app/assets/javascripts/openlayers.js.erb index 206e7177f..9b55a1225 100644 --- a/app/assets/javascripts/openlayers.js.erb +++ b/app/assets/javascripts/openlayers.js.erb @@ -28,34 +28,8 @@ OpenLayers.Util.imageURLs = { "img/zoom-world-mini.png": "<%= asset_path 'img/zoom-world-mini.png' %>" }; -OpenLayers.Util.origCreateDiv = OpenLayers.Util.createDiv; +OpenLayers.Util.origGetImageLocation = OpenLayers.Util.getImageLocation; -OpenLayers.Util.createDiv = function(id, px, sz, imgURL, position, - border, overflow, opacity) { - imgURL = OpenLayers.Util.imageURLs[imgURL] || imgURL; - - return OpenLayers.Util.origCreateDiv(id, px, sz, imgURL, position, - border, overflow, opacity); -}; - -OpenLayers.Util.origCreateImage = OpenLayers.Util.createImage; - -OpenLayers.Util.createImage = function(id, px, sz, imgURL, position, border, - opacity, delayDisplay) { - imgURL = OpenLayers.Util.imageURLs[imgURL] || imgURL; - - return OpenLayers.Util.origCreateImage(id, px, sz, imgURL, position, - border, opacity, delayDisplay); -}; - -OpenLayers.Util.origModifyAlphaImageDiv = OpenLayers.Util.modifyAlphaImageDiv; - -OpenLayers.Util.modifyAlphaImageDiv = function(div, id, px, sz, imgURL, - position, border, sizing, - opacity) { - imgURL = OpenLayers.Util.imageURLs[imgURL] || imgURL; - - return OpenLayers.Util.origModifyAlphaImageDiv(div, id, px, sz, imgURL, - position, border, sizing, - opacity); +OpenLayers.Util.getImageLocation = function(image) { + return OpenLayers.Util.imageURLs[image] || OpenLayers.Util.origGetImageLocation(image); };