From b2ea705d93c560e82ca3822f768d5448589b6b10 Mon Sep 17 00:00:00 2001 From: Victor Häggqvist Date: Fri, 15 Jan 2016 01:26:30 +0100 Subject: call on all closings --- src/LightBox.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/LightBox.js') diff --git a/src/LightBox.js b/src/LightBox.js index abfbd0e..a89d0c4 100644 --- a/src/LightBox.js +++ b/src/LightBox.js @@ -92,7 +92,7 @@ export class LightBox { if (this.image !== null && this.target.href === this.image.src) { log.info('quitting'); - this.quitLightbox(); + if (this.options.quitOnDocClick) this.quitLightbox(); } } @@ -158,12 +158,11 @@ export class LightBox { ) ) ) { - //quitLightbox(); + this.quitLightbox(); return false; } log.debug('unload'); - CSSUtil.setTransitionProperty(this.image, 'opacity '+this.options.animationSpeed/1000+'s linear'); let transitionArgs = '0px'; @@ -268,8 +267,7 @@ export class LightBox { log.debug('click'); if (this.options.quitOnImgClick) { - L.i('implement this'); - //quitLightbox(); + this.quitLightbox(); return false; } -- cgit v1.2.3