hello - i've made an image slide show which works with either a next button, or if you click on the right or left of the screen it shows the next slide.
problem is when i click the next button the click bind also fires which means it move forward 2 slides.
How can i get the click bind to ignore the click if th next button is clicked?!
$(opts.next).click(function(){
nextSlide();
});
function nextSlide() {
$slides.eq(currentSlide).fadeOut(opts.speed)
currentSlide++;
(currentSlide==totalSlides ? currentSlide=0 : false);
updateSlideSHow()
}
function previousSlide() {
$slides.eq(currentSlide).fadeOut(opts.speed)
currentSlide--;
(currentSlide<0 ? currentSlide=(totalSlides-1) : false);
updateSlideSHow()
}
$(this).bind('mouseup',function(e){
var ww = $(window).width();
(e.pageX < (ww/2) ? previousSlide() : nextSlide());
//alert(e.pageX+"<"+ww);
});
any help appreciated!