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

Side by Side Diff: content/public/renderer/render_view.h

Issue 1750863002: Revert of Separate RenderView from RenderWidget, part 1: inheritance. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@renderwidgettest
Patch Set: Created 4 years, 9 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 | « no previous file | content/public/renderer/render_view_observer.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 #ifndef CONTENT_PUBLIC_RENDERER_RENDER_VIEW_H_ 5 #ifndef CONTENT_PUBLIC_RENDERER_RENDER_VIEW_H_
6 #define CONTENT_PUBLIC_RENDERER_RENDER_VIEW_H_ 6 #define CONTENT_PUBLIC_RENDERER_RENDER_VIEW_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 20 matching lines...) Expand all
31 } 31 }
32 32
33 namespace gfx { 33 namespace gfx {
34 class Point; 34 class Point;
35 class Size; 35 class Size;
36 } 36 }
37 37
38 namespace content { 38 namespace content {
39 39
40 class RenderFrame; 40 class RenderFrame;
41 class RenderWidget;
42 class RenderViewVisitor; 41 class RenderViewVisitor;
43 struct SSLStatus; 42 struct SSLStatus;
44 struct WebPreferences; 43 struct WebPreferences;
45 44
46 // DEPRECATED: RenderView is being removed as part of the SiteIsolation project. 45 // DEPRECATED: RenderView is being removed as part of the SiteIsolation project.
47 // New code should be added to RenderFrame instead. 46 // New code should be added to RenderFrame instead.
48 // 47 //
49 // For context, please see https://crbug.com/467770 and 48 // For context, please see https://crbug.com/467770 and
50 // http://www.chromium.org/developers/design-documents/site-isolation. 49 // http://www.chromium.org/developers/design-documents/site-isolation.
51 class CONTENT_EXPORT RenderView : public IPC::Sender { 50 class CONTENT_EXPORT RenderView : public IPC::Sender {
52 public: 51 public:
53 // Returns the RenderView containing the given WebView. 52 // Returns the RenderView containing the given WebView.
54 static RenderView* FromWebView(blink::WebView* webview); 53 static RenderView* FromWebView(blink::WebView* webview);
55 54
56 // Returns the RenderView for the given routing ID. 55 // Returns the RenderView for the given routing ID.
57 static RenderView* FromRoutingID(int routing_id); 56 static RenderView* FromRoutingID(int routing_id);
58 57
59 // Returns the number of live RenderView instances in this process. 58 // Returns the number of live RenderView instances in this process.
60 static size_t GetRenderViewCount(); 59 static size_t GetRenderViewCount();
61 60
62 // Visit all RenderViews with a live WebView (i.e., RenderViews that have 61 // Visit all RenderViews with a live WebView (i.e., RenderViews that have
63 // been closed but not yet destroyed are excluded). 62 // been closed but not yet destroyed are excluded).
64 static void ForEach(RenderViewVisitor* visitor); 63 static void ForEach(RenderViewVisitor* visitor);
65 64
66 // Applies WebKit related preferences to this view. 65 // Applies WebKit related preferences to this view.
67 static void ApplyWebPreferences(const WebPreferences& preferences, 66 static void ApplyWebPreferences(const WebPreferences& preferences,
68 blink::WebView* web_view); 67 blink::WebView* web_view);
69 68
70 // Returns the RenderWidget for this RenderView.
71 virtual RenderWidget* GetWidget() const = 0;
72
73 // Returns the main RenderFrame. 69 // Returns the main RenderFrame.
74 virtual RenderFrame* GetMainRenderFrame() = 0; 70 virtual RenderFrame* GetMainRenderFrame() = 0;
75 71
76 // Get the routing ID of the view. 72 // Get the routing ID of the view.
77 virtual int GetRoutingID() const = 0; 73 virtual int GetRoutingID() const = 0;
78 74
79 // Returns the size of the view. 75 // Returns the size of the view.
80 virtual gfx::Size GetSize() const = 0; 76 virtual gfx::Size GetSize() const = 0;
81 77
82 // Returns the device scale factor of the display the render view is in. 78 // Returns the device scale factor of the display the render view is in.
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 148
153 private: 149 private:
154 // This interface should only be implemented inside content. 150 // This interface should only be implemented inside content.
155 friend class RenderViewImpl; 151 friend class RenderViewImpl;
156 RenderView() {} 152 RenderView() {}
157 }; 153 };
158 154
159 } // namespace content 155 } // namespace content
160 156
161 #endif // CONTENT_PUBLIC_RENDERER_RENDER_VIEW_H_ 157 #endif // CONTENT_PUBLIC_RENDERER_RENDER_VIEW_H_
OLDNEW
« no previous file with comments | « no previous file | content/public/renderer/render_view_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698