kmoskwiak / videojs-resolution-switcher

Resolution switcher adds the ability to select the video quality in video.js player.
https://kmoskwiak.github.io/videojs-resolution-switcher/
Other
403 stars 243 forks source link

When switching the resolution, no unselect previous #96

Open jabiertxof opened 7 years ago

jabiertxof commented 7 years ago

When switching the resolution, no unselect previous. The stream is correctly changed but all clicked options show as selected. Thanks in advance for fix it.

screenshot from 2017-09-06 18-41-37

davypyle commented 6 years ago

I fixed this by just removing the previous selected class on click. Hope this helps someone else.

videojs-resolution-switcher.js Line 37: ResolutionMenuItem.prototype.handleClick = function(event){ Line 38: $(".vjs-menu-item").removeClass("vjs-selected"); //Added using JQuery