summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--js/lightbox.js2
-rw-r--r--js/lightbox_lite.js8
2 files changed, 7 insertions, 3 deletions
diff --git a/js/lightbox.js b/js/lightbox.js
index 24b2deb..161b499 100644
--- a/js/lightbox.js
+++ b/js/lightbox.js
@@ -675,7 +675,7 @@ var Lightbox = {
$('#lightbox').hide();
$("#overlay").fadeOut();
// replaces calls to showSelectBoxes() and showFlash() in original lightbox2
- $("select, object, embed").css({zIndex: '10500'}).show();
+ $("select[display!='none'], object[display!='none'], embed[display!='none']").show();
},
diff --git a/js/lightbox_lite.js b/js/lightbox_lite.js
index fc58b2e..f5dc6c7 100644
--- a/js/lightbox_lite.js
+++ b/js/lightbox_lite.js
@@ -213,7 +213,9 @@ function showLightbox(objLink) {
// Hide select boxes as they will 'peek' through the image in IE
selects = document.getElementsByTagName("select");
for (i = 0; i != selects.length; i++) {
- selects[i].style.visibility = "hidden";
+ if (selects[i].style.display != "none") {
+ selects[i].style.visibility = "hidden";
+ }
}
objLightbox.style.display = 'block';
@@ -256,7 +258,9 @@ function hideLightbox() {
// make select boxes visible
selects = document.getElementsByTagName("select");
for (i = 0; i != selects.length; i++) {
- selects[i].style.visibility = "visible";
+ if (selects[i].style.display != "none") {
+ selects[i].style.visibility = "visible";
+ }
}
// disable keypress listener