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

Side by Side Diff: chrome/browser/extensions/extension_host.h

Issue 9600036: Move Render(View|Widget)Host and associated classes to content namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Respond to review comments. Created 8 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 | Annotate | Revision Log
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 CHROME_BROWSER_EXTENSIONS_EXTENSION_HOST_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_HOST_H_
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_HOST_H_ 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_HOST_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 // (unless SendShouldClose is called again). 105 // (unless SendShouldClose is called again).
106 void CancelShouldClose(); 106 void CancelShouldClose();
107 107
108 // Handles the close ACK. The sequence ID lets us identify whether we have 108 // Handles the close ACK. The sequence ID lets us identify whether we have
109 // cancelled this close sequence. 109 // cancelled this close sequence.
110 void OnShouldCloseAck(int sequence_id); 110 void OnShouldCloseAck(int sequence_id);
111 111
112 const Extension* extension() const { return extension_; } 112 const Extension* extension() const { return extension_; }
113 const std::string& extension_id() const { return extension_id_; } 113 const std::string& extension_id() const { return extension_id_; }
114 content::WebContents* host_contents() const { return host_contents_.get(); } 114 content::WebContents* host_contents() const { return host_contents_.get(); }
115 RenderViewHost* render_view_host() const; 115 content::RenderViewHost* render_view_host() const;
116 content::RenderProcessHost* render_process_host() const; 116 content::RenderProcessHost* render_process_host() const;
117 bool did_stop_loading() const { return did_stop_loading_; } 117 bool did_stop_loading() const { return did_stop_loading_; }
118 bool document_element_available() const { 118 bool document_element_available() const {
119 return document_element_available_; 119 return document_element_available_;
120 } 120 }
121 121
122 Profile* profile() const { return profile_; } 122 Profile* profile() const { return profile_; }
123 123
124 content::ViewType extension_host_type() const { return extension_host_type_; } 124 content::ViewType extension_host_type() const { return extension_host_type_; }
125 const GURL& GetURL() const; 125 const GURL& GetURL() const;
(...skipping 14 matching lines...) Expand all
140 140
141 // Insert a default style sheet for Extension Infobars. 141 // Insert a default style sheet for Extension Infobars.
142 void InsertInfobarCSS(); 142 void InsertInfobarCSS();
143 143
144 // Tell the renderer not to draw scrollbars on windows smaller than 144 // Tell the renderer not to draw scrollbars on windows smaller than
145 // |size_limit| in both width and height. 145 // |size_limit| in both width and height.
146 void DisableScrollbarsForSmallWindows(const gfx::Size& size_limit); 146 void DisableScrollbarsForSmallWindows(const gfx::Size& size_limit);
147 147
148 // content::WebContentsObserver 148 // content::WebContentsObserver
149 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; 149 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
150 virtual void RenderViewCreated(RenderViewHost* render_view_host) OVERRIDE; 150 virtual void RenderViewCreated(
151 virtual void RenderViewDeleted(RenderViewHost* render_view_host) OVERRIDE; 151 content::RenderViewHost* render_view_host) OVERRIDE;
152 virtual void RenderViewDeleted(
153 content::RenderViewHost* render_view_host) OVERRIDE;
152 virtual void RenderViewReady() OVERRIDE; 154 virtual void RenderViewReady() OVERRIDE;
153 virtual void RenderViewGone(base::TerminationStatus status) OVERRIDE; 155 virtual void RenderViewGone(base::TerminationStatus status) OVERRIDE;
154 virtual void DocumentAvailableInMainFrame() OVERRIDE; 156 virtual void DocumentAvailableInMainFrame() OVERRIDE;
155 virtual void DocumentLoadedInFrame(int64 frame_id) OVERRIDE; 157 virtual void DocumentLoadedInFrame(int64 frame_id) OVERRIDE;
156 virtual void DidStopLoading() OVERRIDE; 158 virtual void DidStopLoading() OVERRIDE;
157 159
158 // content::WebContentsDelegate 160 // content::WebContentsDelegate
159 virtual content::WebContents* OpenURLFromTab( 161 virtual content::WebContents* OpenURLFromTab(
160 content::WebContents* source, 162 content::WebContents* source,
161 const content::OpenURLParams& params) OVERRIDE; 163 const content::OpenURLParams& params) OVERRIDE;
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
233 235
234 // The host for our HTML content. 236 // The host for our HTML content.
235 scoped_ptr<content::WebContents> host_contents_; 237 scoped_ptr<content::WebContents> host_contents_;
236 238
237 // Helpers that take care of extra functionality for our host contents. 239 // Helpers that take care of extra functionality for our host contents.
238 scoped_ptr<PrefsTabHelper> prefs_tab_helper_; 240 scoped_ptr<PrefsTabHelper> prefs_tab_helper_;
239 241
240 // A weak pointer to the current or pending RenderViewHost. We don't access 242 // A weak pointer to the current or pending RenderViewHost. We don't access
241 // this through the host_contents because we want to deal with the pending 243 // this through the host_contents because we want to deal with the pending
242 // host, so we can send messages to it before it finishes loading. 244 // host, so we can send messages to it before it finishes loading.
243 RenderViewHost* render_view_host_; 245 content::RenderViewHost* render_view_host_;
244 246
245 // Whether the RenderWidget has reported that it has stopped loading. 247 // Whether the RenderWidget has reported that it has stopped loading.
246 bool did_stop_loading_; 248 bool did_stop_loading_;
247 249
248 // True if the main frame has finished parsing. 250 // True if the main frame has finished parsing.
249 bool document_element_available_; 251 bool document_element_available_;
250 252
251 // The original URL of the page being hosted. 253 // The original URL of the page being hosted.
252 GURL initial_url_; 254 GURL initial_url_;
253 255
(...skipping 11 matching lines...) Expand all
265 PerfTimer since_created_; 267 PerfTimer since_created_;
266 268
267 // A unique ID associated with each call to ShouldClose. This allows us 269 // A unique ID associated with each call to ShouldClose. This allows us
268 // to differentiate which ShouldClose message the renderer is responding to. 270 // to differentiate which ShouldClose message the renderer is responding to.
269 int close_sequence_id_; 271 int close_sequence_id_;
270 272
271 DISALLOW_COPY_AND_ASSIGN(ExtensionHost); 273 DISALLOW_COPY_AND_ASSIGN(ExtensionHost);
272 }; 274 };
273 275
274 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_HOST_H_ 276 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_HOST_H_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_function_dispatcher.cc ('k') | chrome/browser/extensions/extension_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698