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

Side by Side Diff: content/renderer/media/android/proxy_media_keys.cc

Issue 107413006: Dismiss EME infobar when WebMediaPlayer is destroyed. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: make FakeProfile class happy Created 6 years, 11 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "content/renderer/media/android/proxy_media_keys.h" 5 #include "content/renderer/media/android/proxy_media_keys.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 14 matching lines...) Expand all
25 media_keys_id_(media_keys_id), 25 media_keys_id_(media_keys_id),
26 session_created_cb_(session_created_cb), 26 session_created_cb_(session_created_cb),
27 session_message_cb_(session_message_cb), 27 session_message_cb_(session_message_cb),
28 session_ready_cb_(session_ready_cb), 28 session_ready_cb_(session_ready_cb),
29 session_closed_cb_(session_closed_cb), 29 session_closed_cb_(session_closed_cb),
30 session_error_cb_(session_error_cb) { 30 session_error_cb_(session_error_cb) {
31 DCHECK(manager_); 31 DCHECK(manager_);
32 } 32 }
33 33
34 ProxyMediaKeys::~ProxyMediaKeys() { 34 ProxyMediaKeys::~ProxyMediaKeys() {
35 manager_->CancelAllPendingSessionCreations(media_keys_id_);
35 } 36 }
36 37
37 void ProxyMediaKeys::InitializeCDM(const std::string& key_system, 38 void ProxyMediaKeys::InitializeCDM(const std::string& key_system,
38 const GURL& frame_url) { 39 const GURL& frame_url) {
39 #if defined(ENABLE_PEPPER_CDMS) 40 #if defined(ENABLE_PEPPER_CDMS)
40 NOTIMPLEMENTED(); 41 NOTIMPLEMENTED();
41 #elif defined(OS_ANDROID) 42 #elif defined(OS_ANDROID)
42 std::vector<uint8> uuid = GetUUID(key_system); 43 std::vector<uint8> uuid = GetUUID(key_system);
43 DCHECK(!uuid.empty()); 44 DCHECK(!uuid.empty());
44 manager_->InitializeCDM(media_keys_id_, this, uuid, frame_url); 45 manager_->InitializeCDM(media_keys_id_, this, uuid, frame_url);
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 session_closed_cb_.Run(session_id); 90 session_closed_cb_.Run(session_id);
90 } 91 }
91 92
92 void ProxyMediaKeys::OnSessionError(uint32 session_id, 93 void ProxyMediaKeys::OnSessionError(uint32 session_id,
93 media::MediaKeys::KeyError error_code, 94 media::MediaKeys::KeyError error_code,
94 int system_code) { 95 int system_code) {
95 session_error_cb_.Run(session_id, error_code, system_code); 96 session_error_cb_.Run(session_id, error_code, system_code);
96 } 97 }
97 98
98 } // namespace content 99 } // namespace content
OLDNEW
« no previous file with comments | « content/public/test/test_browser_context.cc ('k') | content/renderer/media/android/renderer_media_player_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698