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

Side by Side Diff: content/renderer/dom_automation_controller.cc

Issue 2628053003: Remove extension group from DOMWrapperWorld. (Closed)
Patch Set: Fix GCCallbackTest Created 3 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 unified diff | Download patch
« no previous file with comments | « content/renderer/dom_automation_controller.h ('k') | content/renderer/render_frame_impl.h » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/renderer/dom_automation_controller.h" 5 #include "content/renderer/dom_automation_controller.h"
6 6
7 #include "base/json/json_string_value_serializer.h" 7 #include "base/json/json_string_value_serializer.h"
8 #include "base/strings/string_util.h" 8 #include "base/strings/string_util.h"
9 #include "content/child/v8_value_converter_impl.h" 9 #include "content/child/v8_value_converter_impl.h"
10 #include "content/common/child_process_messages.h" 10 #include "content/common/child_process_messages.h"
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 .SetMethod("send", &DomAutomationController::SendMsg) 53 .SetMethod("send", &DomAutomationController::SendMsg)
54 .SetMethod("setAutomationId", &DomAutomationController::SetAutomationId) 54 .SetMethod("setAutomationId", &DomAutomationController::SetAutomationId)
55 .SetMethod("sendJSON", &DomAutomationController::SendJSON) 55 .SetMethod("sendJSON", &DomAutomationController::SendJSON)
56 .SetMethod("sendWithId", &DomAutomationController::SendWithId); 56 .SetMethod("sendWithId", &DomAutomationController::SendWithId);
57 } 57 }
58 58
59 void DomAutomationController::OnDestruct() {} 59 void DomAutomationController::OnDestruct() {}
60 60
61 void DomAutomationController::DidCreateScriptContext( 61 void DomAutomationController::DidCreateScriptContext(
62 v8::Local<v8::Context> context, 62 v8::Local<v8::Context> context,
63 int extension_group,
64 int world_id) { 63 int world_id) {
65 // Add the domAutomationController to isolated worlds as well. 64 // Add the domAutomationController to isolated worlds as well.
66 v8::Isolate* isolate = blink::mainThreadIsolate(); 65 v8::Isolate* isolate = blink::mainThreadIsolate();
67 v8::HandleScope handle_scope(isolate); 66 v8::HandleScope handle_scope(isolate);
68 if (context.IsEmpty()) 67 if (context.IsEmpty())
69 return; 68 return;
70 69
71 v8::Context::Scope context_scope(context); 70 v8::Context::Scope context_scope(context);
72 71
73 // Resuse this object instead of creating others. 72 // Resuse this object instead of creating others.
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 return Send( 136 return Send(
138 new FrameHostMsg_DomOperationResponse(routing_id(), str)); 137 new FrameHostMsg_DomOperationResponse(routing_id(), str));
139 } 138 }
140 139
141 bool DomAutomationController::SetAutomationId(int automation_id) { 140 bool DomAutomationController::SetAutomationId(int automation_id) {
142 automation_id_ = automation_id; 141 automation_id_ = automation_id;
143 return true; 142 return true;
144 } 143 }
145 144
146 } // namespace content 145 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/dom_automation_controller.h ('k') | content/renderer/render_frame_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698