add a credits line for each routing service
This commit is contained in:
parent
f383fe2793
commit
acf7cf5738
6 changed files with 15 additions and 0 deletions
|
@ -211,6 +211,8 @@ OSM.Routing=function(map,name,jqSearch) {
|
||||||
$('#turnbyturn').append(row);
|
$('#turnbyturn').append(row);
|
||||||
cumulative+=step[3];
|
cumulative+=step[3];
|
||||||
}
|
}
|
||||||
|
$('#sidebar_content').append('<p id="routing_credit">' + r.chosenEngine.creditline + '</p>');
|
||||||
|
|
||||||
};
|
};
|
||||||
r.clickTurn=function(num,latlng) {
|
r.clickTurn=function(num,latlng) {
|
||||||
r.popup=L.popup().setLatLng(latlng).setContent("<p>"+(num+1)+"</p>").openOn(r.map);
|
r.popup=L.popup().setLatLng(latlng).setContent("<p>"+(num+1)+"</p>").openOn(r.map);
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
|
|
||||||
OSM.RoutingEngines.list.push({
|
OSM.RoutingEngines.list.push({
|
||||||
name: "javascripts.directions.engines.cloudmade_foot",
|
name: "javascripts.directions.engines.cloudmade_foot",
|
||||||
|
creditline: 'Directions courtesy of <a href="http://cloudmade.com/products/routing" target="_blank">Cloudmade</a>',
|
||||||
draggable: false,
|
draggable: false,
|
||||||
CM_SPRITE_MAP: {
|
CM_SPRITE_MAP: {
|
||||||
"C": 1,
|
"C": 1,
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
OSM.RoutingEngines.list.push({
|
OSM.RoutingEngines.list.push({
|
||||||
name: "javascripts.directions.engines.graphhopper_bike",
|
name: "javascripts.directions.engines.graphhopper_bike",
|
||||||
|
creditline: 'Directions courtesy of <a href="http://graphhopper.com/routing/" target="_blank">Graphhopper</a>',
|
||||||
draggable: true,
|
draggable: true,
|
||||||
_hints: {},
|
_hints: {},
|
||||||
getRoute: function(isFinal, points) {
|
getRoute: function(isFinal, points) {
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
|
|
||||||
OSM.RoutingEngines.list.push({
|
OSM.RoutingEngines.list.push({
|
||||||
name: "javascripts.directions.engines.mapquest_bike",
|
name: "javascripts.directions.engines.mapquest_bike",
|
||||||
|
creditline: 'Directions courtesy of <a href="http://www.mapquest.com/" target="_blank">MapQuest</a> <img src="http://developer.mapquest.com/content/osm/mq_logo.png">',
|
||||||
draggable: false,
|
draggable: false,
|
||||||
_hints: {},
|
_hints: {},
|
||||||
MQ_SPRITE_MAP: {
|
MQ_SPRITE_MAP: {
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
|
|
||||||
OSM.RoutingEngines.list.push({
|
OSM.RoutingEngines.list.push({
|
||||||
name: "javascripts.directions.engines.osrm_car",
|
name: "javascripts.directions.engines.osrm_car",
|
||||||
|
creditline: 'Directions courtesy of <a href="http://project-osrm.org/" target="_blank">OSRM</a>',
|
||||||
draggable: true,
|
draggable: true,
|
||||||
_hints: {},
|
_hints: {},
|
||||||
getRoute: function(isFinal,points) {
|
getRoute: function(isFinal,points) {
|
||||||
|
|
|
@ -1217,6 +1217,15 @@ tr.turn:hover {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Rules for the routing sidebar */
|
||||||
|
|
||||||
|
#sidebar_content {
|
||||||
|
#routing_credit {
|
||||||
|
text-align: center;
|
||||||
|
padding: 0.5em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Rules for edit pages */
|
/* Rules for edit pages */
|
||||||
|
|
||||||
.site-edit {
|
.site-edit {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue