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

Side by Side Diff: content/browser/frame_host/render_frame_host_impl.h

Issue 1303773002: Give the main frame a RenderWidget. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: plumb through surface ID *and* widget surface ID for window.open Created 5 years, 3 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 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_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ 5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_
6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_
7 7
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 RenderViewHostImpl* render_view_host() { return render_view_host_; } 214 RenderViewHostImpl* render_view_host() { return render_view_host_; }
215 RenderFrameHostDelegate* delegate() { return delegate_; } 215 RenderFrameHostDelegate* delegate() { return delegate_; }
216 FrameTreeNode* frame_tree_node() { return frame_tree_node_; } 216 FrameTreeNode* frame_tree_node() { return frame_tree_node_; }
217 217
218 // Returns this RenderFrameHost's loading state. This method is only used by 218 // Returns this RenderFrameHost's loading state. This method is only used by
219 // FrameTreeNode. The proper way to check whether a frame is loading is to 219 // FrameTreeNode. The proper way to check whether a frame is loading is to
220 // call FrameTreeNode::IsLoading. 220 // call FrameTreeNode::IsLoading.
221 bool is_loading() const { return is_loading_; } 221 bool is_loading() const { return is_loading_; }
222 222
223 // This returns the RenderFrameHost's owned RenderWidgetHost if it has one, 223 // This returns the RenderFrameHost's owned RenderWidgetHost if it has one,
224 // or else it returns nullptr. 224 // or else it returns nullptr.
ncarter (slow) 2015/09/03 20:24:37 I think these comments aren't quite clear enough t
dcheng 2015/09/03 21:29:24 Done.
225 // If the RenderFrameHost is the page's main frame, this returns instead a 225 // If the RenderFrameHost is the page's main frame, this returns instead a
226 // pointer to the RenderViewHost (which inherits RenderWidgetHost). 226 // pointer to the RenderViewHost (which inherits RenderWidgetHost).
227 RenderWidgetHostImpl* GetRenderWidgetHost(); 227 RenderWidgetHostImpl* GetRenderWidgetHost();
228 228
229 // Similar to the above, but if the RenderFrameHost is the main frame, it
230 // returns the RenderWidgetHost owned by the main RenderFrameHost rather than
231 // the RenderViewHost.
232 RenderWidgetHostImpl* GetRenderWidgetHostForFrame() {
233 return render_widget_host_;
234 }
235
229 // This returns the RenderWidgetHostView that can be used to control 236 // This returns the RenderWidgetHostView that can be used to control
230 // focus and visibility for this frame. 237 // focus and visibility for this frame.
231 RenderWidgetHostView* GetView(); 238 RenderWidgetHostView* GetView();
232 239
233 // This function is called when this is a swapped out RenderFrameHost that 240 // This function is called when this is a swapped out RenderFrameHost that
234 // lives in the same process as the parent frame. The 241 // lives in the same process as the parent frame. The
235 // |cross_process_frame_connector| allows the non-swapped-out 242 // |cross_process_frame_connector| allows the non-swapped-out
236 // RenderFrameHost for a frame to communicate with the parent process 243 // RenderFrameHost for a frame to communicate with the parent process
237 // so that it may composite drawing data. 244 // so that it may composite drawing data.
238 // 245 //
(...skipping 540 matching lines...) Expand 10 before | Expand all | Expand 10 after
779 786
780 // NOTE: This must be the last member. 787 // NOTE: This must be the last member.
781 base::WeakPtrFactory<RenderFrameHostImpl> weak_ptr_factory_; 788 base::WeakPtrFactory<RenderFrameHostImpl> weak_ptr_factory_;
782 789
783 DISALLOW_COPY_AND_ASSIGN(RenderFrameHostImpl); 790 DISALLOW_COPY_AND_ASSIGN(RenderFrameHostImpl);
784 }; 791 };
785 792
786 } // namespace content 793 } // namespace content
787 794
788 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ 795 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698