summaryrefslogtreecommitdiff
path: root/lib/gallery.common.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/gallery.common.js')
-rw-r--r--lib/gallery.common.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/gallery.common.js b/lib/gallery.common.js
index 6e3efe5a..618c556e 100644
--- a/lib/gallery.common.js
+++ b/lib/gallery.common.js
@@ -113,10 +113,11 @@
$.fn.gallery_context_menu = function() {
if ($(".gContextMenu li").length) {
+ var hover_target = ".gContextMenu";
var in_progress = 0;
- $(".gContextMenu *").removeAttr('title');
- $(".gContextMenu ul").hide();
- $(".gContextMenu li").hover(
+ $(hover_target + " *").removeAttr('title');
+ $(hover_target + " ul").hide();
+ $(hover_target).hover(
function() {
if (in_progress == 0) {
$(this).find("ul").slideDown("fast", function() { in_progress = 1; });
@@ -125,7 +126,7 @@
}
},
function() {
- $(this).find(".gContext").slideUp("slow", function() { in_progress = 0; });
+ $(this).find("ul").slideUp("slow", function() { in_progress = 0; });
}
);
}