changeset 811:136fc3320f50 jquery

some small additions to birdview
author hertzhaft
date Mon, 21 Feb 2011 00:57:32 +0100
parents 2985cdae5414
children b484631f37c1
files client/digitallibrary/jquery/jquery.digilib.birdseye.js
diffstat 1 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/client/digitallibrary/jquery/jquery.digilib.birdseye.js	Sun Feb 20 13:28:14 2011 +0100
+++ b/client/digitallibrary/jquery/jquery.digilib.birdseye.js	Mon Feb 21 00:57:32 2011 +0100
@@ -7,6 +7,9 @@
     // affine geometry plugin stub
     var geom;
 
+    // digilib object
+    var digilib;
+
     var FULL_AREA;
 
     var buttons = {
@@ -44,7 +47,8 @@
     };
 
     // plugin installation called by digilib on plugin object.
-    var install = function(digilib) {
+    var install = function(plugin) {
+        digilib = plugin;
         console.debug('installing birdseye plugin. digilib:', digilib);
         // import geometry classes
         geom = digilib.fn.geometry;
@@ -229,6 +233,7 @@
             birdZoomRect = geom.rectangle($birdZoom);
             scalerPos = geom.position($scaler);
             newRect = null;
+            data.$elem.find(".overlay").hide(); // hide all overlays (marks/regions)
             fullRect = digilib.fn.setZoomBG(data); // setup zoom background image
             $document.bind("mousemove.dlBirdMove", birdZoomMove);
             $document.bind("mouseup.dlBirdMove", birdZoomEndDrag);