From 449ea290866e1971078f598b21e3343d27833939 Mon Sep 17 00:00:00 2001 From: ahocevar Date: Thu, 1 Oct 2009 19:47:31 +0000 Subject: [PATCH] added option to turn of animation. r=crschmidt,tschaub (closes #2286) git-svn-id: http://svn.openlayers.org/trunk/openlayers@9696 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf --- lib/OpenLayers/Layer/VirtualEarth.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/lib/OpenLayers/Layer/VirtualEarth.js b/lib/OpenLayers/Layer/VirtualEarth.js index d6be0a57ed..e29bc366e2 100644 --- a/lib/OpenLayers/Layer/VirtualEarth.js +++ b/lib/OpenLayers/Layer/VirtualEarth.js @@ -70,7 +70,15 @@ OpenLayers.Layer.VirtualEarth = OpenLayers.Class( * projection, which allows support for vector drawing, overlaying * other maps, etc. */ - sphericalMercator: false, + sphericalMercator: false, + + /** + * APIProperty: animationEnabled + * {Boolean} If set to true, the transition between zoom levels will be + * animated. Set to false to match the zooming experience of other + * layer types. Default is true. + */ + animationEnabled: true, /** * Constructor: OpenLayers.Layer.VirtualEarth @@ -117,6 +125,9 @@ OpenLayers.Layer.VirtualEarth = OpenLayers.Class( } catch (e) { } this.mapObject.HideDashboard(); + if(typeof this.mapObject.SetAnimationEnabled == "function") { + this.mapObject.SetAnimationEnabled(this.animationEnabled); + } } //can we do smooth panning? this is an unpublished method, so we need