OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ |
6 #define CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ | 6 #define CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
126 | 126 |
127 class CONTENT_EXPORT RenderFrameImpl | 127 class CONTENT_EXPORT RenderFrameImpl |
128 : public RenderFrame, | 128 : public RenderFrame, |
129 NON_EXPORTED_BASE(public blink::WebFrameClient), | 129 NON_EXPORTED_BASE(public blink::WebFrameClient), |
130 NON_EXPORTED_BASE(public media::WebMediaPlayerDelegate) { | 130 NON_EXPORTED_BASE(public media::WebMediaPlayerDelegate) { |
131 public: | 131 public: |
132 // Creates a new RenderFrame as the main frame of |render_view|. | 132 // Creates a new RenderFrame as the main frame of |render_view|. |
133 static RenderFrameImpl* CreateMainFrame(RenderViewImpl* render_view, | 133 static RenderFrameImpl* CreateMainFrame(RenderViewImpl* render_view, |
134 int32 routing_id); | 134 int32 routing_id); |
135 | 135 |
136 // Creates a new RenderFrame with |routing_id| as a child of the RenderFrame | 136 // Creates a new RenderFrame with |routing_id|. If |proxy_routing_id| is |
137 // identified by |parent_routing_id| or as the top-level frame if the latter | 137 // MSG_ROUTING_NONE, it creates the Blink WebLocalFrame and inserts it into |
138 // is MSG_ROUTING_NONE. If |proxy_routing_id| is MSG_ROUTING_NONE, it creates | 138 // the frame tree after the frame identified by |
139 // the Blink WebLocalFrame and inserts it into the frame tree after the frame | 139 // |previous_sibling_routing_id|, or as the first child if |
140 // identified by |previous_sibling_routing_id|, or as the first child if | |
141 // |previous_sibling_routing_id| is MSG_ROUTING_NONE. Otherwise, the frame is | 140 // |previous_sibling_routing_id| is MSG_ROUTING_NONE. Otherwise, the frame is |
142 // semi-orphaned until it commits, at which point it replaces the proxy | 141 // semi-orphaned until it commits, at which point it replaces the proxy |
143 // identified by |proxy_routing_id|. Note: This is called only when | 142 // identified by |proxy_routing_id|. The frame's opener is set to the frame |
| 143 // identified by |opener_routing_id|. The frame is created as a child of the |
| 144 // RenderFrame identified by |parent_routing_id| or as the top-level frame if |
| 145 // the latter is MSG_ROUTING_NONE. Note: This is called only when |
144 // RenderFrame is being created in response to IPC message from the browser | 146 // RenderFrame is being created in response to IPC message from the browser |
145 // process. All other frame creation is driven through Blink and Create. | 147 // process. All other frame creation is driven through Blink and Create. |
146 static void CreateFrame(int routing_id, | 148 static void CreateFrame(int routing_id, |
| 149 int proxy_routing_id, |
| 150 int opener_routing_id, |
147 int parent_routing_id, | 151 int parent_routing_id, |
148 int previous_sibling_routing_id, | 152 int previous_sibling_routing_id, |
149 int proxy_routing_id, | |
150 const FrameReplicationState& replicated_state, | 153 const FrameReplicationState& replicated_state, |
151 CompositorDependencies* compositor_deps, | 154 CompositorDependencies* compositor_deps, |
152 const FrameMsg_NewFrame_WidgetParams& params); | 155 const FrameMsg_NewFrame_WidgetParams& params); |
153 | 156 |
154 // Returns the RenderFrameImpl for the given routing ID. | 157 // Returns the RenderFrameImpl for the given routing ID. |
155 static RenderFrameImpl* FromRoutingID(int routing_id); | 158 static RenderFrameImpl* FromRoutingID(int routing_id); |
156 | 159 |
157 // Just like RenderFrame::FromWebFrame but returns the implementation. | 160 // Just like RenderFrame::FromWebFrame but returns the implementation. |
158 static RenderFrameImpl* FromWebFrame(blink::WebFrame* web_frame); | 161 static RenderFrameImpl* FromWebFrame(blink::WebFrame* web_frame); |
159 | 162 |
(...skipping 875 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1035 #endif | 1038 #endif |
1036 | 1039 |
1037 base::WeakPtrFactory<RenderFrameImpl> weak_factory_; | 1040 base::WeakPtrFactory<RenderFrameImpl> weak_factory_; |
1038 | 1041 |
1039 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl); | 1042 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl); |
1040 }; | 1043 }; |
1041 | 1044 |
1042 } // namespace content | 1045 } // namespace content |
1043 | 1046 |
1044 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ | 1047 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ |
OLD | NEW |