You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

68 lines
1.4 KiB

// JavaScript Document
$('.ddw').val(0);
$('.ddw2').val(0);
setTimeout(function(){
$('.num').eq(0).find('p').stop().animate({'top':'50%'},500)
},500);
$(function(){
$('.num_box').mousewheel(function(event, delta) {
var aaaa=$('.ddw2').val();
if (aaaa == 1){
return;
}
qpgd(delta);
});
});
function qpgd(a){
var z =$('.ddw').val();
b = parseInt(z);
c = $('.num').length;
if(a<0){
if(-b==c-1){
return;
}
b-=1;
$('.ddw2').val(1);
}else if(a>0){
if(-b==0){
return;
}
b+=1;
$('.ddw2').val(1);
}
$('.ddw').val(b);
$('.fixed_r li').eq(-b).addClass('on').siblings('li').removeClass('on');
var single_hh = $(window).height();
click_hh =-single_hh*b;
$('.num_box').animate({'bottom': click_hh},1000);
setTimeout(function(){
$('.ddw2').val(0);
},1400);
}
$('.fixed_r li').eq(0).addClass('on');
$('.fixed_r li').click(function(){
var b = $(this).index();
$(this).addClass('on').siblings('li').removeClass('on');
$('.ddw').val(-b);
/*---------------------*/
/*---------------------*/
var single_hh = $(window).height();
click_hh =single_hh*b;
$('.num_box').animate({'bottom': click_hh},100);
})
function quanp(){
var single_hh = $(window).height();
var single_ww = $(window).width();
$('.num').height(single_hh);
$('.num li').width(single_ww);
}
quanp();
$(window).resize(function(){
if (typeof indexSlides != 'undefined' && indexSlides.reformat)
indexSlides.reformat();
quanp();
});