Authored by 2586703@qq.com

swipe ipad调试

... ... @@ -72,7 +72,7 @@ define('yohood', function(require, exports) {
limitedPrev = $('.limited-slide-prev');
limitedNext = $('.limited-slide-next');
swiperLen = $('.limited-slide-box').find('.box').size();
goodsSwiper = swipe.init({
/*goodsSwiper = swipe.init({
slideBox: '.limited-slide-box',
prev: '.limited-slide-prev',
next: '.limited-slide-next',
... ... @@ -89,7 +89,7 @@ define('yohood', function(require, exports) {
limitedPrev.addClass('disable');
};
}
/*touchstart: function() {
touchstart: function() {
limitedPrev.removeClass('disable');
limitedNext.removeClass('disable');
if (index === swiperLen - 1) {
... ... @@ -98,8 +98,24 @@ define('yohood', function(require, exports) {
if (index === 0) {
limitedPrev.addClass('disable');
};
}*/
});
}
});*/
goodsSwiper = Swipe($('.limited-slide-box'), {
auto: false,
callback: function(index, element) {
limitedPrev.removeClass('disable');
limitedNext.removeClass('disable');
console.log(index);
console.log(swiperLen);
if (index === swiperLen - 1) {
limitedNext.addClass('disable');
};
if (index === 0) {
limitedPrev.addClass('disable');
};
}
})
limitedPrev.addClass('disable');
/*limitedNext.on('click', function() {
limitedPrev.removeClass('disable');
... ...