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

Unified Diff: content/browser/renderer_host/render_widget_host_impl.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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/render_widget_host_impl.h
diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h
index 76257b301fcef26b13594f473768c2220f5d7569..8b1a04929d02bbbfcad0b141f7a473ebc996a786 100644
--- a/content/browser/renderer_host/render_widget_host_impl.h
+++ b/content/browser/renderer_host/render_widget_host_impl.h
@@ -25,18 +25,15 @@
#include "ui/gfx/native_widget_types.h"
class BackingStore;
+class MockRenderWidgetHost;
+class WebCursor;
struct EditCommand;
struct ViewHostMsg_UpdateRect_Params;
-class WebCursor;
namespace base {
class TimeTicks;
}
-namespace content {
-class RenderWidgetHostViewPort;
-}
-
namespace ui {
class Range;
}
@@ -48,16 +45,18 @@ struct WebCompositionUnderline;
struct WebScreenInfo;
}
+namespace content {
+
+class RenderWidgetHostViewPort;
+
// This implements the RenderWidgetHost interface that is exposed to
// embedders of content, and adds things only visible to content.
-//
-// TODO(joi): Move to content namespace.
class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
public IPC::Channel::Listener {
public:
// routing_id can be MSG_ROUTING_NONE, in which case the next available
// routing id is taken from the RenderProcessHost.
- RenderWidgetHostImpl(content::RenderProcessHost* process, int routing_id);
+ RenderWidgetHostImpl(RenderProcessHost* process, int routing_id);
virtual ~RenderWidgetHostImpl();
// Use RenderWidgetHostImpl::From(rwh) to downcast a
@@ -95,9 +94,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
virtual void ForwardKeyboardEvent(
const NativeWebKeyboardEvent& key_event) OVERRIDE;
virtual const gfx::Point& GetLastScrollOffset() const OVERRIDE;
- virtual content::RenderProcessHost* GetProcess() const OVERRIDE;
+ virtual RenderProcessHost* GetProcess() const OVERRIDE;
virtual int GetRoutingID() const OVERRIDE;
- virtual content::RenderWidgetHostView* GetView() const OVERRIDE;
+ virtual RenderWidgetHostView* GetView() const OVERRIDE;
virtual bool IsRenderView() const OVERRIDE;
virtual void PaintAtSize(TransportDIB::Handle dib_handle,
int tag,
@@ -112,7 +111,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
virtual bool OnMessageReceivedForTesting(const IPC::Message& msg) OVERRIDE;
// Sets the View of this RenderWidgetHost.
- void SetView(content::RenderWidgetHostView* view);
+ void SetView(RenderWidgetHostView* view);
int surface_id() const { return surface_id_; }
bool renderer_accessible() { return renderer_accessible_; }
@@ -406,7 +405,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
// crashes, its View is destroyed and this pointer becomes NULL, even though
// render_view_host_ lives on to load another URL (creating a new View while
// doing so).
- content::RenderWidgetHostViewPort* view_;
+ RenderWidgetHostViewPort* view_;
// true if a renderer has once been valid. We use this flag to display a sad
// tab only when we lose our renderer and not if a paint occurs during
@@ -417,10 +416,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
int hung_renderer_delay_ms_;
private:
- FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostTest, Resize);
- FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostTest, ResizeThenCrash);
- FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostTest, HiddenPaint);
- FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostTest, PaintAtSize);
+ friend class ::MockRenderWidgetHost;
// Tell this object to destroy itself.
void Destroy();
@@ -526,7 +522,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
// Created during construction but initialized during Init*(). Therefore, it
// is guaranteed never to be NULL, but its channel may be NULL if the
// renderer crashed, so you must always check that.
- content::RenderProcessHost* process_;
+ RenderProcessHost* process_;
// The ID of the corresponding object in the Renderer Instance.
int routing_id_;
@@ -679,4 +675,6 @@ class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl);
};
+} // namespace content
+
#endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_
« no previous file with comments | « content/browser/renderer_host/render_widget_host_gtk.cc ('k') | content/browser/renderer_host/render_widget_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698