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

Side by Side Diff: content/renderer/render_frame_proxy.h

Issue 1149793002: Detach old frame on WebFrame::swap. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: print Created 5 years, 6 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 #ifndef CONTENT_RENDERER_RENDER_FRAME_PROXY_H_ 5 #ifndef CONTENT_RENDERER_RENDER_FRAME_PROXY_H_
6 #define CONTENT_RENDERER_RENDER_FRAME_PROXY_H_ 6 #define CONTENT_RENDERER_RENDER_FRAME_PROXY_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "content/common/content_export.h" 10 #include "content/common/content_export.h"
11 #include "ipc/ipc_listener.h" 11 #include "ipc/ipc_listener.h"
12 #include "ipc/ipc_sender.h" 12 #include "ipc/ipc_sender.h"
13 #include "third_party/WebKit/public/web/WebRemoteFrame.h" 13 #include "third_party/WebKit/public/web/WebRemoteFrame.h"
14 #include "third_party/WebKit/public/web/WebRemoteFrameClient.h" 14 #include "third_party/WebKit/public/web/WebRemoteFrameClient.h"
15 #include "url/origin.h" 15 #include "url/origin.h"
16 16
17 struct FrameMsg_BuffersSwapped_Params; 17 struct FrameMsg_BuffersSwapped_Params;
18 struct FrameMsg_CompositorFrameSwapped_Params; 18 struct FrameMsg_CompositorFrameSwapped_Params;
19 19
20 namespace blink { 20 namespace blink {
21 class WebInputEvent; 21 class WebInputEvent;
22 enum class WebDetachReason;
22 } 23 }
23 24
24 namespace content { 25 namespace content {
25 26
26 class ChildFrameCompositingHelper; 27 class ChildFrameCompositingHelper;
27 class RenderFrameImpl; 28 class RenderFrameImpl;
28 class RenderViewImpl; 29 class RenderViewImpl;
29 struct FrameReplicationState; 30 struct FrameReplicationState;
30 31
31 // When a page's frames are rendered by multiple processes, each renderer has a 32 // When a page's frames are rendered by multiple processes, each renderer has a
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 // for a WebRemoteFrame in the frame tree. In this case, this WebRemoteFrame 106 // for a WebRemoteFrame in the frame tree. In this case, this WebRemoteFrame
106 // is not attached to the frame tree and there is no blink::Frame associated 107 // is not attached to the frame tree and there is no blink::Frame associated
107 // with it, so it is not in state where most operations on it will succeed. 108 // with it, so it is not in state where most operations on it will succeed.
108 bool IsMainFrameDetachedFromTree() const; 109 bool IsMainFrameDetachedFromTree() const;
109 110
110 int routing_id() { return routing_id_; } 111 int routing_id() { return routing_id_; }
111 RenderViewImpl* render_view() { return render_view_; } 112 RenderViewImpl* render_view() { return render_view_; }
112 blink::WebRemoteFrame* web_frame() { return web_frame_; } 113 blink::WebRemoteFrame* web_frame() { return web_frame_; }
113 114
114 // blink::WebRemoteFrameClient implementation: 115 // blink::WebRemoteFrameClient implementation:
116 // TODO(lfg): Remove this method once the blink patch lands.
115 virtual void frameDetached(); 117 virtual void frameDetached();
118 virtual void frameDetached(blink::WebDetachReason reason);
116 virtual void postMessageEvent( 119 virtual void postMessageEvent(
117 blink::WebLocalFrame* sourceFrame, 120 blink::WebLocalFrame* sourceFrame,
118 blink::WebRemoteFrame* targetFrame, 121 blink::WebRemoteFrame* targetFrame,
119 blink::WebSecurityOrigin target, 122 blink::WebSecurityOrigin target,
120 blink::WebDOMMessageEvent event); 123 blink::WebDOMMessageEvent event);
121 virtual void initializeChildFrame( 124 virtual void initializeChildFrame(
122 const blink::WebRect& frame_rect, 125 const blink::WebRect& frame_rect,
123 float scale_factor); 126 float scale_factor);
124 virtual void navigate(const blink::WebURLRequest& request, 127 virtual void navigate(const blink::WebURLRequest& request,
125 bool should_replace_current_entry); 128 bool should_replace_current_entry);
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 scoped_refptr<ChildFrameCompositingHelper> compositing_helper_; 162 scoped_refptr<ChildFrameCompositingHelper> compositing_helper_;
160 163
161 RenderViewImpl* render_view_; 164 RenderViewImpl* render_view_;
162 165
163 DISALLOW_COPY_AND_ASSIGN(RenderFrameProxy); 166 DISALLOW_COPY_AND_ASSIGN(RenderFrameProxy);
164 }; 167 };
165 168
166 } // namespace 169 } // namespace
167 170
168 #endif // CONTENT_RENDERER_RENDER_FRAME_PROXY_H_ 171 #endif // CONTENT_RENDERER_RENDER_FRAME_PROXY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698