OLD | NEW |
---|---|
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_OBSERVER_H_ | 5 #ifndef CONTENT_PUBLIC_RENDERER_RENDER_VIEW_OBSERVER_H_ |
6 #define CONTENT_PUBLIC_RENDERER_RENDER_VIEW_OBSERVER_H_ | 6 #define CONTENT_PUBLIC_RENDERER_RENDER_VIEW_OBSERVER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
92 virtual void DidHandleGestureEvent(const WebKit::WebGestureEvent& event) {} | 92 virtual void DidHandleGestureEvent(const WebKit::WebGestureEvent& event) {} |
93 virtual void DidCreatePepperPlugin(RendererPpapiHost* host) {} | 93 virtual void DidCreatePepperPlugin(RendererPpapiHost* host) {} |
94 | 94 |
95 // These match incoming IPCs. | 95 // These match incoming IPCs. |
96 virtual void Navigate(const GURL& url) {} | 96 virtual void Navigate(const GURL& url) {} |
97 virtual void ClosePage() {} | 97 virtual void ClosePage() {} |
98 | 98 |
99 // IPC::Listener implementation. | 99 // IPC::Listener implementation. |
100 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; | 100 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; |
101 | 101 |
102 // IPC::Sender implementation. | |
Leandro Graciá Gil
2013/01/09 16:23:00
If not moved to public, the IPC_MESSAGE_HANDLER_DE
Jói
2013/01/09 19:23:45
Hmm, I don't know if we want to make this public o
Leandro Graciá Gil
2013/01/10 18:58:13
That worked, thanks! No changes required to this f
| |
103 virtual bool Send(IPC::Message* message) OVERRIDE; | |
104 | |
102 protected: | 105 protected: |
103 explicit RenderViewObserver(RenderView* render_view); | 106 explicit RenderViewObserver(RenderView* render_view); |
104 virtual ~RenderViewObserver(); | 107 virtual ~RenderViewObserver(); |
105 | 108 |
106 // IPC::Sender implementation. | |
107 virtual bool Send(IPC::Message* message) OVERRIDE; | |
108 | |
109 RenderView* render_view() const; | 109 RenderView* render_view() const; |
110 int routing_id() { return routing_id_; } | 110 int routing_id() { return routing_id_; } |
111 | 111 |
112 private: | 112 private: |
113 friend class RenderViewImpl; | 113 friend class RenderViewImpl; |
114 | 114 |
115 // This is called by the RenderView when it's going away so that this object | 115 // This is called by the RenderView when it's going away so that this object |
116 // can null out its pointer. | 116 // can null out its pointer. |
117 void RenderViewGone(); | 117 void RenderViewGone(); |
118 | 118 |
119 RenderView* render_view_; | 119 RenderView* render_view_; |
120 // The routing ID of the associated RenderView. | 120 // The routing ID of the associated RenderView. |
121 int routing_id_; | 121 int routing_id_; |
122 | 122 |
123 DISALLOW_COPY_AND_ASSIGN(RenderViewObserver); | 123 DISALLOW_COPY_AND_ASSIGN(RenderViewObserver); |
124 }; | 124 }; |
125 | 125 |
126 } // namespace content | 126 } // namespace content |
127 | 127 |
128 #endif // CONTENT_PUBLIC_RENDERER_RENDER_VIEW_OBSERVER_H_ | 128 #endif // CONTENT_PUBLIC_RENDERER_RENDER_VIEW_OBSERVER_H_ |
OLD | NEW |