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

Side by Side Diff: chromecast/browser/cast_content_browser_client.cc

Issue 1298473004: [Chromecast] Moves persistent UMA client ID handling to common code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: GN updates, initialize pointer to nullptr Created 5 years, 4 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
« no previous file with comments | « chromecast/browser/cast_content_browser_client.h ('k') | chromecast/browser/metrics/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "chromecast/browser/cast_content_browser_client.h" 5 #include "chromecast/browser/cast_content_browser_client.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/base_switches.h" 9 #include "base/base_switches.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 } 88 }
89 #endif 89 #endif
90 90
91 void CastContentBrowserClient::ProcessExiting() { 91 void CastContentBrowserClient::ProcessExiting() {
92 // Finalize CastMediaShlib on media thread to ensure it's not accessed 92 // Finalize CastMediaShlib on media thread to ensure it's not accessed
93 // after Finalize. 93 // after Finalize.
94 media::MediaMessageLoop::GetTaskRunner()->PostTask( 94 media::MediaMessageLoop::GetTaskRunner()->PostTask(
95 FROM_HERE, base::Bind(&media::CastMediaShlib::Finalize)); 95 FROM_HERE, base::Bind(&media::CastMediaShlib::Finalize));
96 } 96 }
97 97
98 void CastContentBrowserClient::SetMetricsClientId(
99 const std::string& client_id) {
100 }
101
102 void CastContentBrowserClient::RegisterMetricsProviders(
103 ::metrics::MetricsService* metrics_service) {
104 }
105
98 content::BrowserMainParts* CastContentBrowserClient::CreateBrowserMainParts( 106 content::BrowserMainParts* CastContentBrowserClient::CreateBrowserMainParts(
99 const content::MainFunctionParams& parameters) { 107 const content::MainFunctionParams& parameters) {
100 return new CastBrowserMainParts(parameters, 108 content::BrowserMainParts* parts = new CastBrowserMainParts(
101 url_request_context_factory_.get(), 109 parameters, url_request_context_factory_.get(),
102 CreateAudioManagerFactory()); 110 CreateAudioManagerFactory());
111 CastBrowserProcess::GetInstance()->SetCastContentBrowserClient(this);
112 return parts;
103 } 113 }
104 114
105 void CastContentBrowserClient::RenderProcessWillLaunch( 115 void CastContentBrowserClient::RenderProcessWillLaunch(
106 content::RenderProcessHost* host) { 116 content::RenderProcessHost* host) {
107 #if !defined(OS_ANDROID) 117 #if !defined(OS_ANDROID)
108 scoped_refptr<media::CmaMessageFilterHost> cma_message_filter( 118 scoped_refptr<media::CmaMessageFilterHost> cma_message_filter(
109 new media::CmaMessageFilterHost( 119 new media::CmaMessageFilterHost(
110 host->GetID(), 120 host->GetID(),
111 base::Bind(&CastContentBrowserClient::CreateMediaPipelineBackend, 121 base::Bind(&CastContentBrowserClient::CreateMediaPipelineBackend,
112 base::Unretained(this)))); 122 base::Unretained(this))));
(...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after
428 process_type, dumps_path, false /* upload */); 438 process_type, dumps_path, false /* upload */);
429 // StartUploaderThread() even though upload is diferred. 439 // StartUploaderThread() even though upload is diferred.
430 // Breakpad-related memory is freed in the uploader thread. 440 // Breakpad-related memory is freed in the uploader thread.
431 crash_handler->StartUploaderThread(); 441 crash_handler->StartUploaderThread();
432 return crash_handler; 442 return crash_handler;
433 } 443 }
434 #endif // !defined(OS_ANDROID) 444 #endif // !defined(OS_ANDROID)
435 445
436 } // namespace shell 446 } // namespace shell
437 } // namespace chromecast 447 } // namespace chromecast
OLDNEW
« no previous file with comments | « chromecast/browser/cast_content_browser_client.h ('k') | chromecast/browser/metrics/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698