-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
mouseout is triggering fadeOut when moving mouse across control bar #602
Comments
…seout element is actually outside the player. videojs#602
…nd fires a new event called vjs-mouseout which accurately detects leaving the vjs element
I think the 2nd option is better. |
I don't think all of the code is needed. The fixEvent function should clean up cross browser issue at least before it gets to this point. Help me understand what this is doing. |
Sorry for the long delay! Been very busy pushing our new player. We're now running videojs 4.0. I don't think fixEvent function does what we need here. The issue here is that the 'mouseout' event fires when you mouseout of individual components on the control bar. See what I mean here- http://jsfiddle.net/sansb/eupHp/. If you run your mouse over the control bar you'll see the mouseover and mouseout events firing rapidly. Because in control-bar.js we bind 'mouseout' to fadeOut and 'mouseover' to fadeIn, fadeOut and fadeIn are getting called rapidly when you run the mouse over the control bar, which makes some of the components on the control bar jitter as you move your mouse. If you try this on the videojs homepage with the control bar size turned all the way up you can see the jitter better. What my patch does is creates a new event for firing the fadeOut function, vjs-mouseout, which is just like mouseout except it only fires when the mouse moves onto an element outside of the player. This was the best solution I could think of at the time. I can think of a few other possible ways to handle it, but this is the most direct. |
Ok cool, thanks. I'm in progress on control bar change that attempts to address this and about 6 or 7 other control bar issues. When I get the pull request up I'd appreciate your input. |
The 'mouseout' event is getting triggered when moving between different parts of the control bar, and this is causing a fadeOut to get called when it shouldn't. The visible effect of this is some elements on the control bar will jitter around when you move the mouse around while a video is playing. This can be seen on the video here http://www.videojs.com/.
The text was updated successfully, but these errors were encountered: