Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Erratic behavior using tabs in Google Chrome (Ver. 13 OSX) #1

Open
zumajoe opened this issue Jul 12, 2011 · 3 comments
Open

Erratic behavior using tabs in Google Chrome (Ver. 13 OSX) #1

zumajoe opened this issue Jul 12, 2011 · 3 comments

Comments

@zumajoe
Copy link

zumajoe commented Jul 12, 2011

Using Google Chrome on the Mac, if you have a vTicker with multiple list items- open a new tab and wait a good amount of time and switch back, the ticker goes crazy fast trying to “catch up”.

@johnantoni
Copy link
Owner

thanks, i've got chrome 13. will look to fix it

@pratiksha
Copy link

the problem is with chrome and setInterval (see http://stackoverflow.com/questions/6951727/setinterval-not-working-properly-on-chrome ). adding these lines appears to fix it for me by pausing when the window is in the background--

    window.addEventListener('focus', function() {
        options.isPaused=false;
    },false);

    window.addEventListener('blur', function() {
        options.isPaused=true;
    },false);

@Cunej
Copy link

Cunej commented Sep 3, 2012

Hi
be sure that you're not using minified version of vticker, otherwise this fix won't work (won't recognize "options").
Lines must be added at around #127, right after this

if(options.mousePause)
{
obj.bind("mouseenter",function(){
options.isPaused = true;
}).bind("mouseleave",function(){
options.isPaused = false;
});
}

so you'll have

if(options.mousePause)
{
obj.bind("mouseenter",function(){
options.isPaused = true;
}).bind("mouseleave",function(){
options.isPaused = false;
});
}

window.addEventListener('focus', function() {
options.isPaused=false;
},false);

window.addEventListener('blur', function() {
options.isPaused=true;
},false);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants