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_BROWSER_RENDER_WIDGET_HOST_DELEGATE_H_ | 5 #ifndef CONTENT_BROWSER_RENDER_WIDGET_HOST_DELEGATE_H_ |
6 #define CONTENT_BROWSER_RENDER_WIDGET_HOST_DELEGATE_H_ | 6 #define CONTENT_BROWSER_RENDER_WIDGET_HOST_DELEGATE_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "build/build_config.h" | 9 #include "build/build_config.h" |
10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
(...skipping 17 matching lines...) Expand all Loading... |
28 // of the RenderWidgetHost. | 28 // of the RenderWidgetHost. |
29 class CONTENT_EXPORT RenderWidgetHostDelegate { | 29 class CONTENT_EXPORT RenderWidgetHostDelegate { |
30 public: | 30 public: |
31 // The RenderWidgetHost is going to be deleted. | 31 // The RenderWidgetHost is going to be deleted. |
32 virtual void RenderWidgetDeleted(RenderWidgetHostImpl* render_widget_host) {} | 32 virtual void RenderWidgetDeleted(RenderWidgetHostImpl* render_widget_host) {} |
33 | 33 |
34 // The RenderWidgetHost got the focus. | 34 // The RenderWidgetHost got the focus. |
35 virtual void RenderWidgetGotFocus(RenderWidgetHostImpl* render_widget_host) {} | 35 virtual void RenderWidgetGotFocus(RenderWidgetHostImpl* render_widget_host) {} |
36 | 36 |
37 // The RenderWidget was resized. | 37 // The RenderWidget was resized. |
38 virtual void RenderWidgetWasResized( | 38 virtual void RenderWidgetWasResized(RenderWidgetHostImpl* render_widget_host, |
39 RenderWidgetHostImpl* render_widget_host) {} | 39 bool width_changed) {} |
40 | 40 |
41 // Callback to give the browser a chance to handle the specified keyboard | 41 // Callback to give the browser a chance to handle the specified keyboard |
42 // event before sending it to the renderer. | 42 // event before sending it to the renderer. |
43 // Returns true if the |event| was handled. Otherwise, if the |event| would | 43 // Returns true if the |event| was handled. Otherwise, if the |event| would |
44 // be handled in HandleKeyboardEvent() method as a normal keyboard shortcut, | 44 // be handled in HandleKeyboardEvent() method as a normal keyboard shortcut, |
45 // |*is_keyboard_shortcut| should be set to true. | 45 // |*is_keyboard_shortcut| should be set to true. |
46 virtual bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event, | 46 virtual bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event, |
47 bool* is_keyboard_shortcut); | 47 bool* is_keyboard_shortcut); |
48 | 48 |
49 // Callback to inform the browser that the renderer did not process the | 49 // Callback to inform the browser that the renderer did not process the |
(...skipping 30 matching lines...) Expand all Loading... |
80 virtual gfx::NativeViewAccessible GetParentNativeViewAccessible(); | 80 virtual gfx::NativeViewAccessible GetParentNativeViewAccessible(); |
81 #endif | 81 #endif |
82 | 82 |
83 protected: | 83 protected: |
84 virtual ~RenderWidgetHostDelegate() {} | 84 virtual ~RenderWidgetHostDelegate() {} |
85 }; | 85 }; |
86 | 86 |
87 } // namespace content | 87 } // namespace content |
88 | 88 |
89 #endif // CONTENT_BROWSER_RENDER_WIDGET_HOST_DELEGATE_H_ | 89 #endif // CONTENT_BROWSER_RENDER_WIDGET_HOST_DELEGATE_H_ |
OLD | NEW |