OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_WIN_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_WIN_H_ |
6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_WIN_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_WIN_H_ |
7 | 7 |
8 #include <atlbase.h> | 8 #include <atlbase.h> |
9 #include <atlapp.h> | 9 #include <atlapp.h> |
10 #include <atlcrack.h> | 10 #include <atlcrack.h> |
11 #include <atlmisc.h> | 11 #include <atlmisc.h> |
12 | 12 |
13 #include "base/task.h" | 13 #include "base/task.h" |
14 #include "chrome/browser/ime_input.h" | 14 #include "chrome/browser/ime_input.h" |
15 #include "chrome/browser/renderer_host/render_widget_host_view.h" | 15 #include "chrome/browser/renderer_host/render_widget_host_view.h" |
16 #include "webkit/glue/webcursor.h" | 16 #include "webkit/glue/webcursor.h" |
17 | 17 |
18 namespace gfx { | 18 namespace gfx { |
19 class Size; | 19 class Size; |
20 class Rect; | 20 class Rect; |
21 } | 21 } |
22 namespace IPC { | 22 namespace IPC { |
23 class Message; | 23 class Message; |
24 } | 24 } |
| 25 |
| 26 class BackingStore; |
25 class RenderWidgetHost; | 27 class RenderWidgetHost; |
26 class WebMouseEvent; | 28 class WebMouseEvent; |
27 | 29 |
28 typedef CWinTraits<WS_CHILD | WS_CLIPCHILDREN | WS_CLIPSIBLINGS, 0> | 30 typedef CWinTraits<WS_CHILD | WS_CLIPCHILDREN | WS_CLIPSIBLINGS, 0> |
29 RenderWidgetHostHWNDTraits; | 31 RenderWidgetHostHWNDTraits; |
30 | 32 |
31 static const wchar_t* const kRenderWidgetHostHWNDClass = | 33 static const wchar_t* const kRenderWidgetHostHWNDClass = |
32 L"Chrome_RenderWidgetHostHWND"; | 34 L"Chrome_RenderWidgetHostHWND"; |
33 | 35 |
34 /////////////////////////////////////////////////////////////////////////////// | 36 /////////////////////////////////////////////////////////////////////////////// |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 virtual gfx::Rect GetViewBounds() const; | 132 virtual gfx::Rect GetViewBounds() const; |
131 virtual void UpdateCursor(const WebCursor& cursor); | 133 virtual void UpdateCursor(const WebCursor& cursor); |
132 virtual void UpdateCursorIfOverSelf(); | 134 virtual void UpdateCursorIfOverSelf(); |
133 virtual void SetIsLoading(bool is_loading); | 135 virtual void SetIsLoading(bool is_loading); |
134 virtual void IMEUpdateStatus(int control, const gfx::Rect& caret_rect); | 136 virtual void IMEUpdateStatus(int control, const gfx::Rect& caret_rect); |
135 virtual void DidPaintRect(const gfx::Rect& rect); | 137 virtual void DidPaintRect(const gfx::Rect& rect); |
136 virtual void DidScrollRect(const gfx::Rect& rect, int dx, int dy); | 138 virtual void DidScrollRect(const gfx::Rect& rect, int dx, int dy); |
137 virtual void RenderViewGone(); | 139 virtual void RenderViewGone(); |
138 virtual void Destroy(); | 140 virtual void Destroy(); |
139 virtual void SetTooltipText(const std::wstring& tooltip_text); | 141 virtual void SetTooltipText(const std::wstring& tooltip_text); |
| 142 virtual BackingStore* AllocBackingStore(const gfx::Size& size); |
140 | 143 |
141 protected: | 144 protected: |
142 // Windows Message Handlers | 145 // Windows Message Handlers |
143 LRESULT OnCreate(CREATESTRUCT* create_struct); | 146 LRESULT OnCreate(CREATESTRUCT* create_struct); |
144 void OnActivate(UINT, BOOL, HWND); | 147 void OnActivate(UINT, BOOL, HWND); |
145 void OnDestroy(); | 148 void OnDestroy(); |
146 void OnPaint(HDC dc); | 149 void OnPaint(HDC dc); |
147 void OnNCPaint(HRGN update_region); | 150 void OnNCPaint(HRGN update_region); |
148 LRESULT OnEraseBkgnd(HDC dc); | 151 LRESULT OnEraseBkgnd(HDC dc); |
149 LRESULT OnSetCursor(HWND window, UINT hittest_code, UINT mouse_message_id); | 152 LRESULT OnSetCursor(HWND window, UINT hittest_code, UINT mouse_message_id); |
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
274 // Whether the renderer is made accessible. | 277 // Whether the renderer is made accessible. |
275 // TODO(jcampan): http://b/issue?id=1432077 This is a temporary work-around | 278 // TODO(jcampan): http://b/issue?id=1432077 This is a temporary work-around |
276 // until that bug is fixed. | 279 // until that bug is fixed. |
277 bool renderer_accessible_; | 280 bool renderer_accessible_; |
278 | 281 |
279 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewWin); | 282 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewWin); |
280 }; | 283 }; |
281 | 284 |
282 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_WIN_H_ | 285 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_WIN_H_ |
283 | 286 |
OLD | NEW |