diff options
-rw-r--r-- | components/plugins/renderer/webview_plugin.cc | 2 | ||||
-rw-r--r-- | components/plugins/renderer/webview_plugin.h | 2 | ||||
-rw-r--r-- | content/public/renderer/render_view_observer.h | 2 | ||||
-rw-r--r-- | content/renderer/cpp_bound_class_unittest.cc | 3 | ||||
-rw-r--r-- | content/renderer/java/java_bridge_dispatcher.cc | 3 | ||||
-rw-r--r-- | content/renderer/java/java_bridge_dispatcher.h | 3 | ||||
-rw-r--r-- | content/renderer/render_frame_impl.cc | 5 | ||||
-rw-r--r-- | content/renderer/render_frame_impl.h | 2 | ||||
-rw-r--r-- | content/renderer/render_view_impl.cc | 4 | ||||
-rw-r--r-- | content/renderer/render_view_impl.h | 2 | ||||
-rw-r--r-- | content/shell/renderer/shell_render_view_observer.cc | 3 | ||||
-rw-r--r-- | content/shell/renderer/shell_render_view_observer.h | 3 | ||||
-rw-r--r-- | content/shell/renderer/webkit_test_runner.cc | 2 | ||||
-rw-r--r-- | content/shell/renderer/webkit_test_runner.h | 3 |
14 files changed, 23 insertions, 16 deletions
diff --git a/components/plugins/renderer/webview_plugin.cc b/components/plugins/renderer/webview_plugin.cc index 22c7ed2..d7f5af5 100644 --- a/components/plugins/renderer/webview_plugin.cc +++ b/components/plugins/renderer/webview_plugin.cc @@ -217,7 +217,7 @@ void WebViewPlugin::didChangeCursor(const WebCursorInfo& cursor) { current_cursor_ = cursor; } -void WebViewPlugin::didClearWindowObject(WebFrame* frame) { +void WebViewPlugin::didClearWindowObject(WebFrame* frame, int world_id) { if (delegate_) delegate_->BindWebFrame(frame); } diff --git a/components/plugins/renderer/webview_plugin.h b/components/plugins/renderer/webview_plugin.h index 4f463a7..608879c 100644 --- a/components/plugins/renderer/webview_plugin.h +++ b/components/plugins/renderer/webview_plugin.h @@ -118,7 +118,7 @@ class WebViewPlugin : public blink::WebPlugin, virtual void didChangeCursor(const blink::WebCursorInfo& cursor); // WebFrameClient methods: - virtual void didClearWindowObject(blink::WebFrame* frame); + virtual void didClearWindowObject(blink::WebFrame* frame, int world_id); // This method is defined in WebPlugin as well as in WebFrameClient, but with // different parameters. We only care about implementing the WebPlugin diff --git a/content/public/renderer/render_view_observer.h b/content/public/renderer/render_view_observer.h index 9578867..26ce9dc 100644 --- a/content/public/renderer/render_view_observer.h +++ b/content/public/renderer/render_view_observer.h @@ -62,7 +62,7 @@ class CONTENT_EXPORT RenderViewObserver : public IPC::Listener, const blink::WebURLError& error) {} virtual void DidCommitProvisionalLoad(blink::WebFrame* frame, bool is_new_navigation) {} - virtual void DidClearWindowObject(blink::WebFrame* frame) {} + virtual void DidClearWindowObject(blink::WebFrame* frame, int world_id) {} virtual void DidCreateDocumentElement(blink::WebFrame* frame) {} virtual void FrameCreated(blink::WebFrame* parent, blink::WebFrame* frame) {} diff --git a/content/renderer/cpp_bound_class_unittest.cc b/content/renderer/cpp_bound_class_unittest.cc index 9504c65..7f6b466 100644 --- a/content/renderer/cpp_bound_class_unittest.cc +++ b/content/renderer/cpp_bound_class_unittest.cc @@ -59,7 +59,8 @@ class TestObserver : public RenderViewObserver { public: explicit TestObserver(RenderView* render_view) : RenderViewObserver(render_view) {} - virtual void DidClearWindowObject(blink::WebFrame* frame) OVERRIDE { + virtual void DidClearWindowObject(blink::WebFrame* frame, + int world_id) OVERRIDE { example_bound_class_.BindToJavascript(frame, "example"); } void set_fallback_method_enabled(bool use_fallback) { diff --git a/content/renderer/java/java_bridge_dispatcher.cc b/content/renderer/java/java_bridge_dispatcher.cc index f7e435c..54aa73b 100644 --- a/content/renderer/java/java_bridge_dispatcher.cc +++ b/content/renderer/java/java_bridge_dispatcher.cc @@ -51,7 +51,8 @@ bool JavaBridgeDispatcher::OnMessageReceived(const IPC::Message& msg) { return handled; } -void JavaBridgeDispatcher::DidClearWindowObject(blink::WebFrame* web_frame) { +void JavaBridgeDispatcher::DidClearWindowObject(blink::WebFrame* web_frame, + int world_id) { // Note that we have to (re)bind all objects, as they will have been unbound // when the window object was cleared. for (ObjectMap::const_iterator iter = objects_.begin(); diff --git a/content/renderer/java/java_bridge_dispatcher.h b/content/renderer/java/java_bridge_dispatcher.h index 325d529..8ab16d1 100644 --- a/content/renderer/java/java_bridge_dispatcher.h +++ b/content/renderer/java/java_bridge_dispatcher.h @@ -30,7 +30,8 @@ class JavaBridgeDispatcher : public RenderViewObserver { private: // RenderViewObserver override: virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; - virtual void DidClearWindowObject(blink::WebFrame* frame) OVERRIDE; + virtual void DidClearWindowObject(blink::WebFrame* frame, + int world_id) OVERRIDE; // Message handlers void OnAddNamedObject(const base::string16& name, diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc index 34b483fa..3085ff4 100644 --- a/content/renderer/render_frame_impl.cc +++ b/content/renderer/render_frame_impl.cc @@ -1058,12 +1058,13 @@ void RenderFrameImpl::didCommitProvisionalLoad(blink::WebFrame* frame, DidCommitProvisionalLoad(frame, is_new_navigation)); } -void RenderFrameImpl::didClearWindowObject(blink::WebFrame* frame) { +void RenderFrameImpl::didClearWindowObject(blink::WebFrame* frame, + int world_id) { // TODO(nasko): Move implementation here. Needed state: // * enabled_bindings_ // * dom_automation_controller_ // * stats_collection_controller_ - render_view_->didClearWindowObject(frame); + render_view_->didClearWindowObject(frame, world_id); } void RenderFrameImpl::didCreateDocumentElement(blink::WebFrame* frame) { diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h index bcdfcfa..8fadd79 100644 --- a/content/renderer/render_frame_impl.h +++ b/content/renderer/render_frame_impl.h @@ -259,7 +259,7 @@ class CONTENT_EXPORT RenderFrameImpl const blink::WebURLError& error); virtual void didCommitProvisionalLoad(blink::WebFrame* frame, bool is_new_navigation); - virtual void didClearWindowObject(blink::WebFrame* frame); + virtual void didClearWindowObject(blink::WebFrame* frame, int world_id); virtual void didCreateDocumentElement(blink::WebFrame* frame); virtual void didReceiveTitle(blink::WebFrame* frame, const blink::WebString& title, diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc index 82e904b..0294c71 100644 --- a/content/renderer/render_view_impl.cc +++ b/content/renderer/render_view_impl.cc @@ -3650,9 +3650,9 @@ void RenderViewImpl::didCommitProvisionalLoad(WebFrame* frame, } } -void RenderViewImpl::didClearWindowObject(WebFrame* frame) { +void RenderViewImpl::didClearWindowObject(WebFrame* frame, int world_id) { FOR_EACH_OBSERVER(RenderViewObserver, observers_, - DidClearWindowObject(frame)); + DidClearWindowObject(frame, world_id)); if (enabled_bindings_ & BINDINGS_POLICY_DOM_AUTOMATION) { if (!dom_automation_controller_) diff --git a/content/renderer/render_view_impl.h b/content/renderer/render_view_impl.h index f9adb7b..756046e 100644 --- a/content/renderer/render_view_impl.h +++ b/content/renderer/render_view_impl.h @@ -543,7 +543,7 @@ class CONTENT_EXPORT RenderViewImpl const blink::WebURLError& error); virtual void didCommitProvisionalLoad(blink::WebFrame* frame, bool is_new_navigation); - virtual void didClearWindowObject(blink::WebFrame* frame); + virtual void didClearWindowObject(blink::WebFrame* frame, int world_id); virtual void didCreateDocumentElement(blink::WebFrame* frame); virtual void didReceiveTitle(blink::WebFrame* frame, const blink::WebString& title, diff --git a/content/shell/renderer/shell_render_view_observer.cc b/content/shell/renderer/shell_render_view_observer.cc index b5b82cd..673a527 100644 --- a/content/shell/renderer/shell_render_view_observer.cc +++ b/content/shell/renderer/shell_render_view_observer.cc @@ -17,7 +17,8 @@ ShellRenderViewObserver::ShellRenderViewObserver(RenderView* render_view) : RenderViewObserver(render_view) { } -void ShellRenderViewObserver::DidClearWindowObject(blink::WebFrame* frame) { +void ShellRenderViewObserver::DidClearWindowObject(blink::WebFrame* frame, + int world_id) { if (CommandLine::ForCurrentProcess()->HasSwitch( switches::kExposeInternalsForTesting)) { blink::WebTestingSupport::injectInternalsObject(frame); diff --git a/content/shell/renderer/shell_render_view_observer.h b/content/shell/renderer/shell_render_view_observer.h index c412779..49ffed7 100644 --- a/content/shell/renderer/shell_render_view_observer.h +++ b/content/shell/renderer/shell_render_view_observer.h @@ -23,7 +23,8 @@ class ShellRenderViewObserver : public RenderViewObserver { private: // RenderViewObserver implementation. - virtual void DidClearWindowObject(blink::WebFrame* frame) OVERRIDE; + virtual void DidClearWindowObject(blink::WebFrame* frame, + int world_id) OVERRIDE; DISALLOW_COPY_AND_ASSIGN(ShellRenderViewObserver); }; diff --git a/content/shell/renderer/webkit_test_runner.cc b/content/shell/renderer/webkit_test_runner.cc index 5d939e1..d733556 100644 --- a/content/shell/renderer/webkit_test_runner.cc +++ b/content/shell/renderer/webkit_test_runner.cc @@ -542,7 +542,7 @@ void WebKitTestRunner::captureHistoryForWindow( // RenderViewObserver -------------------------------------------------------- -void WebKitTestRunner::DidClearWindowObject(WebFrame* frame) { +void WebKitTestRunner::DidClearWindowObject(WebFrame* frame, int world_id) { WebTestingSupport::injectInternalsObject(frame); ShellRenderProcessObserver::GetInstance()->test_interfaces()->bindTo(frame); } diff --git a/content/shell/renderer/webkit_test_runner.h b/content/shell/renderer/webkit_test_runner.h index ab29437..18feed1 100644 --- a/content/shell/renderer/webkit_test_runner.h +++ b/content/shell/renderer/webkit_test_runner.h @@ -41,7 +41,8 @@ class WebKitTestRunner : public RenderViewObserver, // RenderViewObserver implementation. virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; - virtual void DidClearWindowObject(blink::WebFrame* frame) OVERRIDE; + virtual void DidClearWindowObject(blink::WebFrame* frame, + int world_id) OVERRIDE; virtual void Navigate(const GURL& url) OVERRIDE; virtual void DidCommitProvisionalLoad(blink::WebFrame* frame, bool is_new_navigation) OVERRIDE; |