I've tried to implement a pause on hover event to jmpress slider for several days, but it doesn't work fine, it stops the loop after the first (or second) slide.
I tried with: setInterval, mouseenter/mouseleave, hover function, clearTimeout and many other options and functions, but nothing.
You can see the slider here: http://www.meraloasilonido.it/04/
This is the code, I edit it and it stops on hover but doesn't restart again, line 225 of jquery.jmslideshow.js (original file not edited: http://www.meraloasilonido.it/04/js/slider/jquery.jmslideshow.js):
_loadEvents : function() {
var _self = this;
// ADD THIS EDIT
if(this.options.hoverpause && this.options.autoplay){
$('.jms-slideshow').on('mouseenter', function(e){
_self._stopSlideshow();
return false;
} );
$('.jms-slideshow').on('mouseleave', function(e){
_self._startSlideshow();
_self.$jmsWrapper.jmpress( 'next' );
return false;
} );
}
// STOP EDIT
Any suggestions?
Thanks in advance and sorry for my (bad) english. :/