...
|
...
|
@@ -44,6 +44,10 @@ function ImgPreview(url, opt) { |
|
|
});
|
|
|
|
|
|
if (this.$mask) {
|
|
|
this.$mask.css({
|
|
|
width: 'auto',
|
|
|
height: 'auto'
|
|
|
});
|
|
|
this.$mask.on('click', function() {
|
|
|
that.close();
|
|
|
});
|
...
|
...
|
@@ -57,6 +61,7 @@ ImgPreview.prototype = new Dialog({ |
|
|
ImgPreview.prototype.close = function() {
|
|
|
this.$mask && this.$mask.addClass('hide');
|
|
|
this.$el.addClass('hide');
|
|
|
$('body').removeClass('dialog-open');
|
|
|
};
|
|
|
|
|
|
|
...
|
...
|
@@ -71,6 +76,7 @@ ImgPreview.prototype.preview = function(url) { |
|
|
this.refresh();
|
|
|
|
|
|
this.show();
|
|
|
$('body').addClass('dialog-open');
|
|
|
};
|
|
|
|
|
|
ImgPreview.prototype.refresh = function() {
|
...
|
...
|
|