summaryrefslogtreecommitdiffstats
path: root/webkit/glue
diff options
context:
space:
mode:
authorscherkus@chromium.org <scherkus@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-18 22:42:15 +0000
committerscherkus@chromium.org <scherkus@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-18 22:42:15 +0000
commit83f2a8a62298f97b0b8b7ccfb02da26d8abcf96e (patch)
treeec339f6512b03bf215bb64eb66b26097dbf1b36a /webkit/glue
parent6f004f1b37d04d790bd8d15575705bc4840ed74e (diff)
downloadchromium_src-83f2a8a62298f97b0b8b7ccfb02da26d8abcf96e.zip
chromium_src-83f2a8a62298f97b0b8b7ccfb02da26d8abcf96e.tar.gz
chromium_src-83f2a8a62298f97b0b8b7ccfb02da26d8abcf96e.tar.bz2
Finished implementation of hasAudio() to detect media without playback audio tracks.
There is a WebKit side to this patch out for review as well: https://bugs.webkit.org/show_bug.cgi?id=28310 BUG=18970 TEST=play a video without audio (i.e., trek0.ogv), the UI should display a disabled audio icon Review URL: http://codereview.chromium.org/171091 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23671 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue')
-rw-r--r--webkit/glue/webmediaplayer_impl.cc3
-rw-r--r--webkit/glue/webmediaplayer_impl.h2
2 files changed, 4 insertions, 1 deletions
diff --git a/webkit/glue/webmediaplayer_impl.cc b/webkit/glue/webmediaplayer_impl.cc
index 00c6834..9eae37b 100644
--- a/webkit/glue/webmediaplayer_impl.cc
+++ b/webkit/glue/webmediaplayer_impl.cc
@@ -471,6 +471,9 @@ void WebMediaPlayerImpl::OnPipelineInitialize() {
// as format error. Should post a task to call to |webmediaplayer_|.
SetNetworkState(WebKit::WebMediaPlayer::FormatError);
}
+
+ // Repaint to trigger UI update.
+ Repaint();
}
void WebMediaPlayerImpl::OnPipelineSeek() {
diff --git a/webkit/glue/webmediaplayer_impl.h b/webkit/glue/webmediaplayer_impl.h
index bd4a6e8..f6d7fd3 100644
--- a/webkit/glue/webmediaplayer_impl.h
+++ b/webkit/glue/webmediaplayer_impl.h
@@ -181,7 +181,7 @@ class WebMediaPlayerImpl : public WebKit::WebMediaPlayer,
virtual void paint(WebKit::WebCanvas* canvas, const WebKit::WebRect& rect);
- // True if a video is loaded.
+ // True if the loaded media has a playable video/audio track.
virtual bool hasVideo() const;
virtual bool hasAudio() const;