changeset 997:bc969618c42f

make birdseye react to isBirdDivVisible
author hertzhaft
date Mon, 13 Feb 2012 00:40:13 +0100
parents 0b63093d598e
children d084717a1ed9
files webapp/src/main/webapp/jquery/jquery.digilib.birdseye.js
diffstat 1 files changed, 3 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/webapp/src/main/webapp/jquery/jquery.digilib.birdseye.js	Fri Feb 10 12:47:17 2012 +0100
+++ b/webapp/src/main/webapp/jquery/jquery.digilib.birdseye.js	Mon Feb 13 00:40:13 2012 +0100
@@ -101,17 +101,13 @@
     	// TODO: do we need this?
         console.debug("birdseye: handleRedisplay");
         var data = this;
-        if (data.settings.isBirdDivVisible) {
-            updateBirdDiv(data);
-        }
+        actions.showBirdDiv(data, data.settings.isBirdDivVisible);
     };
 
     var handleChangeZoomArea = function (evt, zoomArea) {
         //console.debug("birdseye: handleDragZoom za="+zoomArea);
     	var data = this;
-        if (data.settings.isBirdDivVisible) {
-            updateBirdZoom(data, zoomArea);
-        }
+        updateBirdZoom(data, zoomArea);
     };
 
     // returns URL for bird's eye view image
@@ -223,6 +219,7 @@
 
     // move bird zoom indicator to reflect zoomed detail area
     var updateBirdZoom = function(data, zoomArea) {
+        if (!data.settings.isBirdDivVisible) return;
         var birdRect = data.birdTrafo.transform(zoomArea);
         var $birdZoom = data.$birdZoom;
         // acount for border width