Lines Matching refs:core

45         this.core = $(element).data('lightGallery');
47 this.core.s = $.extend({}, defaults, this.core.s);
49 if (this.core.s.zoom && this.core.doCss()) {
68 if (_this.core.s.actualSize) {
72 if (_this.core.s.useLeftForZoom) {
73 _this.core.$outer.addClass('lg-use-left-for-zoom');
75 _this.core.$outer.addClass('lg-use-transition-for-zoom');
78 this.core.$outer.find('.lg-toolbar').append(zoomIcons);
81 _this.core.$el.on('onSlideItemLoad.lg.tm.zoom', function(event, index, delay) {
84 var _speed = _this.core.s.enableZoomAfter + delay;
98 _this.core.$slide.eq(index).addClass('lg-zoomable');
111 var $image = _this.core.$outer.find('.lg-current .lg-image');
127 if (_this.core.s.useLeftForZoom) {
139 _this.core.$outer.addClass('lg-zoomed');
154 if (_this.core.s.dynamic) {
155 nw = _this.core.s.dynamicEl[index].width || $image[0].naturalWidth || w;
157 nw = _this.core.$items.eq(index).attr('data-width') || $image[0].naturalWidth || w;
162 if (_this.core.$outer.hasClass('lg-zoomed')) {
181 _this.core.$outer.removeClass('lg-grabbing').addClass('lg-grab');
188 _this.core.$el.on('onAferAppendSlide.lg.tm.zoom', function(event, index) {
191 var $image = _this.core.$slide.eq(index).find('.lg-image');
221 if (_this.core.$outer.find('.lg-current .lg-image').length) {
222 scale -= _this.core.s.scale;
228 if (_this.core.$outer.find('.lg-current .lg-image').length) {
229 scale += _this.core.s.scale;
235 …actualSize(event, _this.core.$slide.eq(_this.core.index).find('.lg-image'), _this.core.index, true…
239 _this.core.$el.on('onBeforeSlide.lg.tm', function() {
245 if (!_this.core.isTouch) {
249 if (_this.core.isTouch) {
257 this.core.$outer.removeClass('lg-zoomed');
258 this.core.$slide.find('.lg-img-wrap').removeAttr('style data-x data-y');
259 this.core.$slide.find('.lg-image').removeAttr('style data-scale');
278 _this.core.$slide.on('touchstart.lg', function(e) {
280 if (_this.core.$outer.hasClass('lg-zoomed')) {
281 var $image = _this.core.$slide.eq(_this.core.index).find('.lg-object');
283 …allowY = $image.prop('offsetHeight') * $image.attr('data-scale') > _this.core.$outer.find('.lg').h…
284 …allowX = $image.prop('offsetWidth') * $image.attr('data-scale') > _this.core.$outer.find('.lg').wi…
296 _this.core.$slide.on('touchmove.lg', function(e) {
298 if (_this.core.$outer.hasClass('lg-zoomed')) {
300 var _$el = _this.core.$slide.eq(_this.core.index).find('.lg-img-wrap');
313 _this.core.$outer.addClass('lg-zoom-dragging');
329 if (_this.core.s.useLeftForZoom) {
343 _this.core.$slide.on('touchend.lg', function() {
344 if (_this.core.$outer.hasClass('lg-zoomed')) {
347 _this.core.$outer.removeClass('lg-zoom-dragging');
370 _this.core.$slide.on('mousedown.lg.zoom', function(e) {
373 var $image = _this.core.$slide.eq(_this.core.index).find('.lg-object');
375 …allowY = $image.prop('offsetHeight') * $image.attr('data-scale') > _this.core.$outer.find('.lg').h…
376 …allowX = $image.prop('offsetWidth') * $image.attr('data-scale') > _this.core.$outer.find('.lg').wi…
378 if (_this.core.$outer.hasClass('lg-zoomed')) {
389 _this.core.$outer.scrollLeft += 1;
390 _this.core.$outer.scrollLeft -= 1;
392 _this.core.$outer.removeClass('lg-grab').addClass('lg-grabbing');
399 var _$el = _this.core.$slide.eq(_this.core.index).find('.lg-img-wrap');
410 _this.core.$outer.addClass('lg-zoom-dragging');
424 if (_this.core.s.useLeftForZoom) {
439 _this.core.$outer.removeClass('lg-zoom-dragging');
454 _this.core.$outer.removeClass('lg-grabbing').addClass('lg-grab');
462 var _$el = _this.core.$slide.eq(_this.core.index).find('.lg-img-wrap');
463 var $image = _this.core.$slide.eq(_this.core.index).find('.lg-object');
466 var minY = (_this.core.$outer.find('.lg').height() - $image.prop('offsetHeight')) / 2;
467 …image.prop('offsetHeight') * Math.abs($image.attr('data-scale'))) - _this.core.$outer.find('.lg').…
468 var minX = (_this.core.$outer.find('.lg').width() - $image.prop('offsetWidth')) / 2;
469 …$image.prop('offsetWidth') * Math.abs($image.attr('data-scale'))) - _this.core.$outer.find('.lg').…
500 if (_this.core.s.useLeftForZoom) {
517 _this.core.$el.off('.lg.zoom');
519 _this.core.$slide.off('.lg.zoom');
520 _this.core.$el.off('.lg.tm.zoom');