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

Unified Diff: content/renderer/render_view_impl.cc

Issue 131573003: Convert DomAutomationController from CppBoundClass to gin::Wrappable (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates 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 side-by-side diff with in-line comments
Download patch
« content/renderer/render_view_impl.h ('K') | « content/renderer/render_view_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_view_impl.cc
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
index 0faf36066e10857dc89878d83f761325abf07c14..39d660e8493790002b17c1e4f5ce92b3080516bb 100644
--- a/content/renderer/render_view_impl.cc
+++ b/content/renderer/render_view_impl.cc
@@ -871,6 +871,7 @@ RenderViewImpl::RenderViewImpl(RenderViewImplParams* params)
handling_select_range_(false),
next_snapshot_id_(0),
allow_partial_swap_(params->allow_partial_swap),
+ dom_automation_controller_(NULL),
context_menu_source_type_(ui::MENU_SOURCE_MOUSE) {
}
@@ -3667,12 +3668,8 @@ void RenderViewImpl::didClearWindowObject(WebFrame* frame) {
if (enabled_bindings_ & BINDINGS_POLICY_DOM_AUTOMATION) {
if (!dom_automation_controller_)
- dom_automation_controller_.reset(new DomAutomationController());
- dom_automation_controller_->set_message_sender(
- static_cast<RenderView*>(this));
- dom_automation_controller_->set_routing_id(routing_id());
- dom_automation_controller_->BindToJavascript(frame,
- "domAutomationController");
+ dom_automation_controller_ = new DomAutomationController(this);
+ dom_automation_controller_->Install(frame);
}
if (enabled_bindings_ & BINDINGS_POLICY_STATS_COLLECTION)
« content/renderer/render_view_impl.h ('K') | « content/renderer/render_view_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698