Yes. I just figured that out. Now trying to use :
if ($(event.target).is('.first-one'))
with no positive result. It does not seem to produce the right
conditions. Any suggestions?
- $wrapper.hover(function
() {
-
if (!state.paused) {
- clearInterval(state.interval);
-
state.paused = true;
- }
-
}, function (event) {
-
if (state.paused){
-
var fun = function(){
-
state.interval = setInterval(function () {
-
go(vars.fwd, false);
-
}, settings.animspeed);
- }
-
-
if ($(event.target).is('.first-one')){
-
var time = window.setTimeout(fun, 200);
- }else{
-
var time = window.setTimeout(fun, 9000);
- }
-
-
state.paused = false;
- }
- });
- };
Go function:
- var
go = function(direction, position) {
-
// only if we're not already doing things
- if(!state.animating){
-
// doing things
-
state.animating = true;
- if(position){
-
state.nextslide = position;
-
state.nextindex = position-1;
- }
- else{
- set_next(direction);
- }
-
// fade animation
-
if(settings.animtype === 'fade'){
- if(settings.showmarkers){
- $m_markers.removeClass('active-marker');
- $m_markers.eq(state.nextindex).addClass('active-marker');
- }
-
// fade out current
- $slides.eq(state.currentindex).fadeOut(settings.animduration);
-
// fade in next
-
$slides.eq(state.nextindex).fadeIn(settings.animduration, function(){
-
// update state variables
-
state.animating = false;
-
state.currentslide = state.nextslide;
-
state.currentindex = state.nextindex;
- });
- }
Full code can be found in
bjqs-1.3.js
on
www.posturemedic.ca