Author: sevein
Date: Thu Oct  6 00:44:42 2011
New Revision: 9958

Log:
Digital object browser js fixes

Modified:
   trunk/apps/qubit/modules/digitalobject/templates/browseSuccess.php

Modified: trunk/apps/qubit/modules/digitalobject/templates/browseSuccess.php
==============================================================================
--- trunk/apps/qubit/modules/digitalobject/templates/browseSuccess.php  Wed Oct 
 5 16:53:03 2011        (r9957)
+++ trunk/apps/qubit/modules/digitalobject/templates/browseSuccess.php  Thu Oct 
 6 00:44:42 2011        (r9958)
@@ -19,7 +19,6 @@
           .mouseover(function()
             {
               \$this = $(this).addClass('hover');
-              
             })
           .mouseout(function()
             {
@@ -41,9 +40,20 @@
                     });
 
                 \$layer
-                  .append(\$this.clone(false).wrap('div').addClass('img'))
-                  .append(\$this.nextAll().clone(false).show());
-                
+
+                  .append(
+                    \$this
+                      .clone()
+                      .wrap('div')
+                      .addClass('img')
+                      .css('position', 'static'))
+
+                  .append(
+                    \$this
+                      .nextAll()
+                      .clone()
+                      .show());
+
                 \$layer
                   .css({
                     'top': (\$layer.height() - \$this.height()) / -2,
@@ -66,13 +76,14 @@
         var maxWidth = 0;
         var maxHeight = 0;
 
+        // Calculate maxHeight and maxWidth
         $('.digital-object-browser li').each(function()
           {
             \$this = $(this);
 
             width = \$this.width();
             height = \$this.height();
-            
+
             if (width > maxWidth)
             {
               maxWidth = width;
@@ -82,7 +93,6 @@
             {
               maxHeight = height;
             }
-
           });
 
         // Set maxWidth
@@ -91,17 +101,16 @@
         // Set maxWidth
         $('.digital-object-browser li').height(maxHeight);
 
+        // 
         $('.digital-object-browser li').each(function()
           {
-            \$this = $(this);
-
-            \$this.height(maxHeight);
+            \$anchor = \$(this).find('> a');
 
-            if (maxHeight > \$this.children().height())
+            if (maxHeight > \$anchor.height())
             {
-              \$this.find('> a > img')
+              \$anchor
                 .css('position', 'relative')
-                .css('top', (maxHeight - \$this.children().height()) / 2);
+                .css('top', (maxHeight - \$anchor.height()) / 2);
             }
 
           });

-- 
You received this message because you are subscribed to the Google Groups 
"Qubit Toolkit Commits" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/qubit-commits?hl=en.

Reply via email to