summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoryoshiki <yoshiki@chromium.org>2014-09-13 22:27:36 -0700
committerCommit bot <commit-bot@chromium.org>2014-09-13 22:27:37 -0700
commit97ca04aacc85eb7863ead3fb1e689bef05441e45 (patch)
treea71d2168a26bf093cf9cb8d784a6796dfb7c20ee
parent06053a1b88b541c6f6c83e6e89bbbb9545c1634f (diff)
downloadchromium_src-97ca04aacc85eb7863ead3fb1e689bef05441e45.zip
chromium_src-97ca04aacc85eb7863ead3fb1e689bef05441e45.tar.gz
chromium_src-97ca04aacc85eb7863ead3fb1e689bef05441e45.tar.bz2
Detach video when the another video is loaded
BUG=none TEST=none TBR=fukino@chromium.org Review URL: https://codereview.chromium.org/569663002
-rw-r--r--ui/file_manager/video_player/js/video_player.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/ui/file_manager/video_player/js/video_player.js b/ui/file_manager/video_player/js/video_player.js
index dba0d6a..b941805 100644
--- a/ui/file_manager/video_player/js/video_player.js
+++ b/ui/file_manager/video_player/js/video_player.js
@@ -307,6 +307,7 @@ VideoPlayer.prototype.loadVideo_ = function(video, opt_callback) {
// Re-enables ui and hides error message if already displayed.
document.querySelector('#video-player').removeAttribute('disabled');
document.querySelector('#error').removeAttribute('visible');
+ this.controls.detachMedia();
this.controls.inactivityWatcher.disabled = true;
this.controls.decodeErrorOccured = false;
this.controls.casting = !!this.currentCast_;