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

vjs-lock-showing class gets removed from menu when no longer hovering on menu-button. #1690

Closed
gkatsev opened this issue Nov 25, 2014 · 12 comments
Labels
bug confirmed pinned Things that stalebot shouldn't close automatically

Comments

@gkatsev
Copy link
Member

gkatsev commented Nov 25, 2014

No description provided.

@heff
Copy link
Member

heff commented Nov 26, 2014

What are the steps to reproduce? Is this something that was working and is now broken? If so do you know which version it stopped working in?

@gkatsev
Copy link
Member Author

gkatsev commented Nov 26, 2014

Um... It was working in previous version of vjs (3.x).
Clicking on the captions button sets aria-pressed to true and sets vjs-lock-showing on the vjs-menu-content element. However, as soon as we move away from the button, the vjs-lock-showing class gets removed from the vjs-menu-content element.

@CPColin
Copy link

CPColin commented Nov 26, 2014

This is the part of the code that's doing it:

vjs.MenuButton.prototype.onClick = function(){
  // When you click the button it adds focus, which will show the menu indefinitely.
  // So we'll remove focus when the mouse leaves the button.
  // Focus is needed for tab navigation.
  this.one('mouseout', vjs.bind(this, function(){
    this.menu.unlockShowing();
    this.el_.blur();
  }));
  if (this.buttonPressed_){
    this.unpressButton();
  } else {
    this.pressButton();
  }
};

Specifically, it's that unlockShowing() call, as far as I can tell.

@gkatsev
Copy link
Member Author

gkatsev commented Nov 26, 2014

@CPColin awesome, thanks for tracking it down.

@CPColin
Copy link

CPColin commented Nov 26, 2014

@gkatsev No prob. I had just run into the problem myself and was looking for a workaround.

@CPColin
Copy link

CPColin commented Dec 12, 2014

Has anybody had a chance to look into this? Do we need to do something or provide more details?

@gkatsev
Copy link
Member Author

gkatsev commented Dec 12, 2014

Unfortunately, we're very busy. (See #1736).
If you can make a PR to fix the problem, that would be the fastest way to get this fixed.

@ghost
Copy link

ghost commented Jan 28, 2015

Ran into the problem too and fixed it by downgrading to v4.8.5 as this bug appears in 4.9.0.

@jeffski
Copy link

jeffski commented Jun 9, 2015

+1 this - videojs-speed plugin is broken in latest version because menu items won't stay open. Using v4.8.5 works fine.

@mmcc
Copy link
Member

mmcc commented Jun 9, 2015

@jeffski videojs-speed will only work with 4.8.5 because it's relying on mangled properties. To be honest, that should probably be removed from the plugins list, especially since playback rates are supported in core now.

videojs('my-video', { playbackRates: [ 0.5, 1, 1.5] });

@jeffski
Copy link

jeffski commented Jun 10, 2015

Thanks @mmcc, will try the core way instead.

@gkatsev
Copy link
Member Author

gkatsev commented Jun 10, 2015

Btw, I updated the wiki page to "deprecate" the plugin.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug confirmed pinned Things that stalebot shouldn't close automatically
Projects
None yet
Development

No branches or pull requests

5 participants