initial commit

This commit is contained in:
Norbert Renner 2014-01-27 18:34:48 +01:00
parent 37980ff82b
commit 4cc16bccd0
17 changed files with 789 additions and 0 deletions

20
js/control/Download.js Normal file
View file

@ -0,0 +1,20 @@
BR.Download = BR.Control.extend({
options: {
heading: 'Download'
},
onAdd: function (map) {
var container = BR.Control.prototype.onAdd.call(this, map);
return container;
},
update: function (urls) {
var html = '<div class="label">&nbsp;</div><div class="value">';
if (urls.gpx) {
html += '<a href="' + urls.gpx + '" download="brouter.gpx" target="_blank">GPX</a> &middot; ';
html += '<a href="' + urls.kml + '" download="brouter.kml" target="_blank">KML</a>';
}
html += '</div>'
this._content.innerHTML = html;
}
});