summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/gallery.show_full_size.js35
1 files changed, 15 insertions, 20 deletions
diff --git a/lib/gallery.show_full_size.js b/lib/gallery.show_full_size.js
index 1f74e6e2..7e826c32 100644
--- a/lib/gallery.show_full_size.js
+++ b/lib/gallery.show_full_size.js
@@ -27,27 +27,22 @@
'<img id="gFullSizeImage" src="' + image_url + '"' +
'height="' + image_size.height + '" width="' + image_size.width + '"/></div>');
- //$("#gFullsize").append('<span id="gFullsizeClose" class="fg-button ui-icon ui-state-default ' +
-// 'ui-icon-closethick ui-corner-all" style="z-index: 1003; position: absolute; ' +
-// 'right: 1em; top: 1em;"></span>');
- $("#gFullsize").click(function() {
- $("#gFullsizeOverlay*").remove();
- $("#gFullsize").remove();
- });
+ $().click(function() {
+ $("#gFullsizeOverlay*").remove();
+ $("#gFullsize").remove();
+ });
$().bind("keypress", function() {
- $("#gFullsizeOverlay*").remove();
- $("#gFullsize").remove();
- });
+ $("#gFullsizeOverlay*").remove();
+ $("#gFullsize").remove();
+ });
$(window).resize(function() {
- $("#gFullsizeOverlay").width($(document).width())
- .height($(document).height());
- image_size = $.gallery_auto_fit_window(image_width, image_height);
- $("#gFullsize").height(image_size.height)
- .width(image_size.width)
- .css("top", image_size.top)
- .css("left", image_size.left);
- $("#gFullSizeImage").height(image_size.height)
- .width(image_size.width);
- });
+ $("#gFullsizeOverlay").width($(document).width()).height($(document).height());
+ image_size = $.gallery_auto_fit_window(image_width, image_height);
+ $("#gFullsize").height(image_size.height)
+ .width(image_size.width)
+ .css("top", image_size.top)
+ .css("left", image_size.left);
+ $("#gFullSizeImage").height(image_size.height).width(image_size.width);
+ });
};
})(jQuery);