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

Side by Side Diff: chrome/browser/ui/webui/mojo_web_ui_controller.cc

Issue 2566583002: Change allowed bindings to be per RenderFrame instead of per RenderView. (Closed)
Patch Set: rebase Created 3 years, 10 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 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 "chrome/browser/ui/webui/mojo_web_ui_controller.h" 5 #include "chrome/browser/ui/webui/mojo_web_ui_controller.h"
6 6
7 #include "chrome/browser/profiles/profile.h" 7 #include "chrome/browser/profiles/profile.h"
8 #include "chrome/browser/ui/webui/mojo_web_ui_handler.h" 8 #include "chrome/browser/ui/webui/mojo_web_ui_handler.h"
9 #include "content/public/browser/render_process_host.h" 9 #include "content/public/browser/render_process_host.h"
10 #include "content/public/browser/web_ui_data_source.h" 10 #include "content/public/browser/web_ui_data_source.h"
11 #include "content/public/common/bindings_policy.h" 11 #include "content/public/common/bindings_policy.h"
12 #include "mojo/public/cpp/system/core.h" 12 #include "mojo/public/cpp/system/core.h"
13 13
14 MojoWebUIControllerBase::MojoWebUIControllerBase(content::WebUI* contents) 14 MojoWebUIControllerBase::MojoWebUIControllerBase(content::WebUI* contents)
15 : WebUIController(contents) {} 15 : WebUIController(contents) {}
16 16
17 MojoWebUIControllerBase::~MojoWebUIControllerBase() { 17 MojoWebUIControllerBase::~MojoWebUIControllerBase() {
18 } 18 }
19 19
20 void MojoWebUIControllerBase::RenderFrameCreated( 20 void MojoWebUIControllerBase::RenderFrameCreated(
21 content::RenderFrameHost* render_frame_host) { 21 content::RenderFrameHost* render_frame_host) {
22 render_frame_host->GetRenderViewHost()->AllowBindings( 22 render_frame_host->AllowBindings(content::BINDINGS_POLICY_WEB_UI);
23 content::BINDINGS_POLICY_WEB_UI);
24 } 23 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/browser_navigator_browsertest.cc ('k') | chrome/renderer/chrome_render_view_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698