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

Unified Diff: extensions/shell/browser/shell_browser_main_parts.cc

Issue 573843002: Allows webview to access extension resources. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Forgot to add the namespace on chrome_url_request_util.cc Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « extensions/extensions.gyp ('k') | extensions/shell/browser/shell_extensions_browser_client.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/shell/browser/shell_browser_main_parts.cc
diff --git a/extensions/shell/browser/shell_browser_main_parts.cc b/extensions/shell/browser/shell_browser_main_parts.cc
index a4edc01488bce88194a8a229c3d71b20b37efaee..462f28ca0ba8df1ccaed1e7dbbbc8b07be8733c8 100644
--- a/extensions/shell/browser/shell_browser_main_parts.cc
+++ b/extensions/shell/browser/shell_browser_main_parts.cc
@@ -8,6 +8,7 @@
#include "base/run_loop.h"
#include "components/keyed_service/content/browser_context_dependency_manager.h"
#include "components/omaha_query_params/omaha_query_params.h"
+#include "content/public/browser/child_process_security_policy.h"
#include "content/public/browser/context_factory.h"
#include "content/public/common/result_codes.h"
#include "content/shell/browser/shell_devtools_delegate.h"
@@ -15,6 +16,7 @@
#include "extensions/browser/app_window/apps_client.h"
#include "extensions/browser/browser_context_keyed_service_factories.h"
#include "extensions/browser/extension_system.h"
+#include "extensions/common/constants.cc"
#include "extensions/shell/browser/shell_browser_context.h"
#include "extensions/shell/browser/shell_browser_main_delegate.h"
#include "extensions/shell/browser/shell_desktop_controller.h"
@@ -96,6 +98,11 @@ void ShellBrowserMainParts::PreEarlyInitialization() {
int ShellBrowserMainParts::PreCreateThreads() {
// TODO(jamescook): Initialize chromeos::CrosSettings here?
+ content::ChildProcessSecurityPolicy::GetInstance()->RegisterWebSafeScheme(
+ kExtensionScheme);
+ content::ChildProcessSecurityPolicy::GetInstance()->RegisterWebSafeScheme(
+ kExtensionResourceScheme);
+
// Return no error.
return 0;
}
« no previous file with comments | « extensions/extensions.gyp ('k') | extensions/shell/browser/shell_extensions_browser_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698