diff options
| author | Étienne Loks <etienne.loks@peacefrogs.net> | 2012-08-21 19:23:15 +0200 |
|---|---|---|
| committer | Étienne Loks <etienne.loks@peacefrogs.net> | 2012-08-21 19:23:15 +0200 |
| commit | 95f2f9222fa10b2642bf5e21995fb8fafef9e95c (patch) | |
| tree | 67188f3583e1f1d2c38c85728c4b2a71ec3776eb /chimere/static | |
| parent | 0dec1cea3c49a29d44767ecf4000194755f74a5a (diff) | |
| download | Chimère-95f2f9222fa10b2642bf5e21995fb8fafef9e95c.tar.bz2 Chimère-95f2f9222fa10b2642bf5e21995fb8fafef9e95c.zip | |
Layers: add MapQuest layer management
Diffstat (limited to 'chimere/static')
| -rw-r--r-- | chimere/static/chimere/js/jquery.chimere.js | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/chimere/static/chimere/js/jquery.chimere.js b/chimere/static/chimere/js/jquery.chimere.js index b2de3de..e99eb21 100644 --- a/chimere/static/chimere/js/jquery.chimere.js +++ b/chimere/static/chimere/js/jquery.chimere.js @@ -16,6 +16,22 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. See the file COPYING for details. */ +/* Add OpenLayers MapQuest layer management */ +OpenLayers.Layer.MapQuestOSM = OpenLayers.Class(OpenLayers.Layer.XYZ, { + name: "MapQuestOSM", + sphericalMercator: true, + url: ' http://otile1.mqcdn.com/tiles/1.0.0/osm/${z}/${x}/${y}.png', + clone: function(obj) { + if (obj == null) { + obj = new OpenLayers.Layer.OSM( + this.name, this.url, this.getOptions()); + } + obj = OpenLayers.Layer.XYZ.prototype.clone.apply(this, [obj]); + return obj; + }, + CLASS_NAME: "OpenLayers.Layer.MapQuestOSM" +}); + /* * Little hasattr helper */ |
