I created an edit to the simple.carousel.js to stop the carousel when hovered, but I'm having an issue restarting it when mouseleave. The code that I added to the simple.carousel.js is:
// hover stop
if(config.auto!=true)
$(this).mouseenter(function() {
config.auto=false;
}).mouseleave( function() {
config.auto=true;
});
You can see the full code/example here with my addition from above: http://jsfiddle.net/6r6sC/2/
Is is something wrong with my mouseleave function?
Not sure if this will help, but I've also tried the following but that doesn't work either:
// hover stop
if(config.auto!=true)
$(this).mouseenter(function() {
config.auto=false;
}).mouseleave( function() {
setTimeout(function() {
slide('next');
}, config.auto);
});
Any help would be greatly appreciated, as this has me stumped.