diff options
author | Struan Donald <struan@exo.org.uk> | 2012-03-12 11:20:08 +0000 |
---|---|---|
committer | Struan Donald <struan@exo.org.uk> | 2012-03-12 12:07:43 +0000 |
commit | d14bdc65777a6347c419f29e355fa9f1745de739 (patch) | |
tree | c4bc1cad6ab061d69fd6a58d5dc5b3c44deb79c8 /phonegap/www/js/map-bing.js | |
parent | 1b15ca0aea334d20fb0f19fed36bc948668e2a14 (diff) |
rough initial code for iPhone phonegap app
Diffstat (limited to 'phonegap/www/js/map-bing.js')
-rw-r--r-- | phonegap/www/js/map-bing.js | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/phonegap/www/js/map-bing.js b/phonegap/www/js/map-bing.js new file mode 100644 index 000000000..856e4f188 --- /dev/null +++ b/phonegap/www/js/map-bing.js @@ -0,0 +1,22 @@ +$(function(){ + var centre = new Microsoft.Maps.Location( fixmystreet.latitude, fixmystreet.longitude ); + var map = new Microsoft.Maps.Map(document.getElementById("map"), { + credentials: fixmystreet.key, + mapTypeId: Microsoft.Maps.MapTypeId.ordnanceSurvey, + center: centre, + zoom: 15, + enableClickableLogo: false, + enableSearchLogo: false, + showCopyright: false, + showDashboard: true, + showLogo: false, + showScalebar: false + }); + //minZoomLevel: 14, + //numZoomLevels: 4 + + Microsoft.Maps.Events.addHandler(map, "viewchangestart", function(e) { + /* Doesn't work */ + if (map.getTargetZoom() < 12) return false; + }); +}); |