[OpenLayers-Commits] r11131 - trunk/openlayers/examples

commits-20090109 at openlayers.org commits-20090109 at openlayers.org
Thu Feb 17 00:07:50 EST 2011


Author: tschaub
Date: 2011-02-16 21:07:50 -0800 (Wed, 16 Feb 2011)
New Revision: 11131

Modified:
   trunk/openlayers/examples/mobile-jq.html
Log:
Prevent scrolling from map.

Modified: trunk/openlayers/examples/mobile-jq.html
===================================================================
--- trunk/openlayers/examples/mobile-jq.html	2011-02-16 21:19:08 UTC (rev 11130)
+++ trunk/openlayers/examples/mobile-jq.html	2011-02-17 05:07:50 UTC (rev 11131)
@@ -3,6 +3,7 @@
     <head>
         <title>OpenLayers with jQuery Mobile</title>
         <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0;">
+        <meta name="apple-mobile-web-app-capable" content="yes">
         <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0a3/jquery.mobile-1.0a3.min.css">
         <script src="http://code.jquery.com/jquery-1.5.min.js"></script>
         <script src="http://code.jquery.com/mobile/1.0a3/jquery.mobile-1.0a3.min.js"></script>
@@ -92,6 +93,11 @@
                 
                 $("#nav").click();
                 $("#nav").click(); // jquery mobile bug forces 2 calls to refresh radio ui
+                
+                // disable scrolling from the map
+                $("#map").bind("touchstart", function(event) {
+                    event.preventDefault();
+                });
             });
 
         </script>



More information about the Commits mailing list