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

Side by Side Diff: content/shell/browser/shell_content_browser_client.cc

Issue 1947313002: Enable content embedders to specify mojo application task runner. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: restores mojo:media in browser Created 4 years, 7 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/shell/browser/shell_content_browser_client.h" 5 #include "content/shell/browser/shell_content_browser_client.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/base_switches.h" 10 #include "base/base_switches.h"
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 for (size_t i = 0; i < arraysize(kProtocolList); ++i) { 173 for (size_t i = 0; i < arraysize(kProtocolList); ++i) {
174 if (url.scheme() == kProtocolList[i]) 174 if (url.scheme() == kProtocolList[i])
175 return true; 175 return true;
176 } 176 }
177 return false; 177 return false;
178 } 178 }
179 179
180 void ShellContentBrowserClient::RegisterInProcessMojoApplications( 180 void ShellContentBrowserClient::RegisterInProcessMojoApplications(
181 StaticMojoApplicationMap* apps) { 181 StaticMojoApplicationMap* apps) {
182 #if (ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS) 182 #if (ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS)
183 apps->insert(std::make_pair("mojo:media", 183 content::MojoApplicationInfo app_info;
184 base::Bind(&media::CreateMojoMediaApplication))); 184 app_info.application_factory = base::Bind(&media::CreateMojoMediaApplication);
185 apps->insert(std::make_pair("mojo:media", app_info));
185 #endif 186 #endif
186 } 187 }
187 188
188 void ShellContentBrowserClient::RegisterOutOfProcessMojoApplications( 189 void ShellContentBrowserClient::RegisterOutOfProcessMojoApplications(
189 OutOfProcessMojoApplicationMap* apps) { 190 OutOfProcessMojoApplicationMap* apps) {
190 apps->insert(std::make_pair(kTestMojoAppUrl, 191 apps->insert(std::make_pair(kTestMojoAppUrl,
191 base::UTF8ToUTF16("Test Mojo App"))); 192 base::UTF8ToUTF16("Test Mojo App")));
192 } 193 }
193 194
194 void ShellContentBrowserClient::AppendExtraCommandLineSwitches( 195 void ShellContentBrowserClient::AppendExtraCommandLineSwitches(
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 ShellBrowserContext* 351 ShellBrowserContext*
351 ShellContentBrowserClient::off_the_record_browser_context() { 352 ShellContentBrowserClient::off_the_record_browser_context() {
352 return shell_browser_main_parts_->off_the_record_browser_context(); 353 return shell_browser_main_parts_->off_the_record_browser_context();
353 } 354 }
354 355
355 AccessTokenStore* ShellContentBrowserClient::CreateAccessTokenStore() { 356 AccessTokenStore* ShellContentBrowserClient::CreateAccessTokenStore() {
356 return new ShellAccessTokenStore(browser_context()); 357 return new ShellAccessTokenStore(browser_context());
357 } 358 }
358 359
359 } // namespace content 360 } // namespace content
OLDNEW
« no previous file with comments | « content/public/utility/content_utility_client.h ('k') | content/shell/utility/shell_content_utility_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698