From 5c2c39c9dd6c53f856d6453842da9fb2f70d62fd Mon Sep 17 00:00:00 2001 From: Marc Jansen Date: Mon, 5 Mar 2012 22:27:43 +0100 Subject: [PATCH] Fix the examples that used our '$' method. --- examples/editing-methods.js | 2 ++ examples/game-accel-ball.html | 1 + examples/geolocation.js | 2 +- examples/getfeatureinfo-control.html | 2 +- examples/select-feature.html | 3 +++ examples/snap-split.html | 2 ++ examples/snapping.html | 2 ++ examples/strategy-cluster-extended.js | 2 ++ examples/strategy-cluster-threshold.html | 1 + examples/strategy-cluster.html | 2 ++ examples/tilecache.html | 2 +- examples/using-proj4js.js | 2 ++ 12 files changed, 20 insertions(+), 3 deletions(-) diff --git a/examples/editing-methods.js b/examples/editing-methods.js index 6c139a276d..9ed961eaf9 100644 --- a/examples/editing-methods.js +++ b/examples/editing-methods.js @@ -19,6 +19,8 @@ var draw = new OpenLayers.Control.DrawFeature( map.addControl(draw); draw.activate(); +$ = OpenLayers.Util.getElement; + // handle clicks on method links $("insertXY").onclick = function() { var values = parseInput( diff --git a/examples/game-accel-ball.html b/examples/game-accel-ball.html index 40bb02d791..a622768bd2 100644 --- a/examples/game-accel-ball.html +++ b/examples/game-accel-ball.html @@ -33,6 +33,7 @@ vlayer.drawFeature(feature); } function init() { + var $ = OpenLayers.Util.getElement; map = new OpenLayers.Map( 'map', { 'maxExtent': new OpenLayers.Bounds(0, 0, $("map").clientWidth, $("map").clientHeight), diff --git a/examples/geolocation.js b/examples/geolocation.js index 1afc12d997..acde5faae5 100644 --- a/examples/geolocation.js +++ b/examples/geolocation.js @@ -92,7 +92,7 @@ geolocate.events.register("locationupdated",geolocate,function(e) { geolocate.events.register("locationfailed",this,function() { OpenLayers.Console.log('Location detection failed'); }); - +var $ = OpenLayers.Util.getElement; $('locate').onclick = function() { vector.removeAllFeatures(); geolocate.deactivate(); diff --git a/examples/getfeatureinfo-control.html b/examples/getfeatureinfo-control.html index cb0bec10e4..2dcdf3c58d 100644 --- a/examples/getfeatureinfo-control.html +++ b/examples/getfeatureinfo-control.html @@ -48,7 +48,7 @@