disable subtitles if disabled via options.enableSubtitles, fixes #2898

This commit is contained in:
j 2016-03-05 15:38:52 +05:30
parent 3637b70244
commit 07ec93179c

View file

@ -2343,7 +2343,7 @@ Ox.VideoPlayer = function(options, self) {
} }
function setSubtitlesTrack() { function setSubtitlesTrack() {
var enableSubtitles = !!self.options.subtitlesTrack, var enableSubtitles = self.options.enableSubtitles && !!self.options.subtitlesTrack,
toggleSubtitles = enableSubtitles != self.options.enableSubtitles; toggleSubtitles = enableSubtitles != self.options.enableSubtitles;
self.options.enableSubtitles = enableSubtitles; self.options.enableSubtitles = enableSubtitles;
setSubtitle(); setSubtitle();