Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8)

Side by Side Diff: webkit/media/webmediaplayer_impl.cc

Issue 12713004: Add Chromium-side changes for MediaSource::isTypeSupported() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Exclude StreamParserFactory for Android Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "webkit/media/webmediaplayer_impl.h" 5 #include "webkit/media/webmediaplayer_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 955 matching lines...) Expand 10 before | Expand all | Expand 10 after
966 break; 966 break;
967 } 967 }
968 968
969 // Repaint to trigger UI update. 969 // Repaint to trigger UI update.
970 Repaint(); 970 Repaint();
971 } 971 }
972 972
973 void WebMediaPlayerImpl::OnDemuxerOpened( 973 void WebMediaPlayerImpl::OnDemuxerOpened(
974 scoped_ptr<WebKit::WebMediaSource> media_source) { 974 scoped_ptr<WebKit::WebMediaSource> media_source) {
975 DCHECK(main_loop_->BelongsToCurrentThread()); 975 DCHECK(main_loop_->BelongsToCurrentThread());
976 media_source->open(new WebMediaSourceClientImpl(chunk_demuxer_)); 976 media_source->open(new WebMediaSourceClientImpl(
977 chunk_demuxer_, base::Bind(&LogMediaSourceError, media_log_)));
977 } 978 }
978 979
979 void WebMediaPlayerImpl::OnKeyAdded(const std::string& key_system, 980 void WebMediaPlayerImpl::OnKeyAdded(const std::string& key_system,
980 const std::string& session_id) { 981 const std::string& session_id) {
981 DCHECK(main_loop_->BelongsToCurrentThread()); 982 DCHECK(main_loop_->BelongsToCurrentThread());
982 983
983 base::Histogram::FactoryGet( 984 base::Histogram::FactoryGet(
984 kMediaEme + KeySystemNameForUMA(key_system) + ".KeyAdded", 985 kMediaEme + KeySystemNameForUMA(key_system) + ".KeyAdded",
985 1, 1000000, 50, 986 1, 1000000, 50,
986 base::Histogram::kUmaTargetedHistogramFlag)->Add(1); 987 base::Histogram::kUmaTargetedHistogramFlag)->Add(1);
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
1197 1198
1198 if (pending_repaint_) 1199 if (pending_repaint_)
1199 return; 1200 return;
1200 1201
1201 pending_repaint_ = true; 1202 pending_repaint_ = true;
1202 main_loop_->PostTask(FROM_HERE, base::Bind( 1203 main_loop_->PostTask(FROM_HERE, base::Bind(
1203 &WebMediaPlayerImpl::Repaint, AsWeakPtr())); 1204 &WebMediaPlayerImpl::Repaint, AsWeakPtr()));
1204 } 1205 }
1205 1206
1206 } // namespace webkit_media 1207 } // namespace webkit_media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698