Replace gmaps-link by popup with qrcode and links

If you want to use your smartphone for navigation, you can now just scan
the qr-code and (if your scanner-app supports it) directly input the
locations to your navigation-app.
Additionally a link to the location in gapps and OSM will be displayed.
This commit is contained in:
Axel Wagner
2013-02-25 16:21:03 +01:00
parent 633dad97b9
commit 107f4689e9
4 changed files with 18 additions and 3 deletions

View File

@ -96,6 +96,14 @@ window.rangeLinkClick = function() {
window.smartphone.mapButton.click();
}
window.showPortalPosLinks = function(lat, lng) {
var qrcode = '<div id="qrcode"></div>';
var script = '<script>$("#qrcode").qrcode({text:"GEO:'+lat+','+lng+'"});</script>';
var gmaps = '<a href="https://maps.google.com/?q='+lat+','+lng+'">gmaps</a>';
var osm = '<a href="http://www.openstreetmap.org/?mlat='+lat+'&mlon='+lng+'&zoom=16">OSM</a>';
alert(qrcode + script + gmaps + " " + osm);
}
window.reportPortalIssue = function(info) {
var t = 'Redirecting you to a Google Help Page. Once there, click on “Contact Us” in the upper right corner.\n\nThe text box contains all necessary information. Press CTRL+C to copy it.';
var d = window.portals[window.selectedPortal].options.details;