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_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ |
6 #define CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ | 6 #define CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 // Returns true if the View's context menu is showing. | 95 // Returns true if the View's context menu is showing. |
96 virtual bool IsShowingContextMenu() const = 0; | 96 virtual bool IsShowingContextMenu() const = 0; |
97 | 97 |
98 // Tells the View whether the context menu is showing. | 98 // Tells the View whether the context menu is showing. |
99 virtual void SetShowingContextMenu(bool showing) = 0; | 99 virtual void SetShowingContextMenu(bool showing) = 0; |
100 | 100 |
101 // Returns the currently selected text. | 101 // Returns the currently selected text. |
102 virtual base::string16 GetSelectedText() const = 0; | 102 virtual base::string16 GetSelectedText() const = 0; |
103 | 103 |
104 // Subclasses should override this method to do what is appropriate to set | 104 // Subclasses should override this method to do what is appropriate to set |
105 // the custom background for their platform. | 105 // the background to be transparent or opaque. |
106 virtual void SetBackground(const SkBitmap& background) = 0; | 106 virtual void SetBackgroundOpaque(bool opaque) = 0; |
107 virtual const SkBitmap& GetBackground() = 0; | 107 virtual bool GetBackgroundOpaque() = 0; |
108 | 108 |
109 // Return value indicates whether the mouse is locked successfully or not. | 109 // Return value indicates whether the mouse is locked successfully or not. |
110 virtual bool LockMouse() = 0; | 110 virtual bool LockMouse() = 0; |
111 virtual void UnlockMouse() = 0; | 111 virtual void UnlockMouse() = 0; |
112 // Returns true if the mouse pointer is currently locked. | 112 // Returns true if the mouse pointer is currently locked. |
113 virtual bool IsMouseLocked() = 0; | 113 virtual bool IsMouseLocked() = 0; |
114 | 114 |
115 // Retrives the size of the viewport for the visible region. May be smaller | 115 // Retrives the size of the viewport for the visible region. May be smaller |
116 // than the view size if a portion of the view is obstructed (e.g. by a | 116 // than the view size if a portion of the view is obstructed (e.g. by a |
117 // virtual keyboard). | 117 // virtual keyboard). |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 // Returns |true| if text is currently being spoken by Mac OS X. | 162 // Returns |true| if text is currently being spoken by Mac OS X. |
163 virtual bool IsSpeaking() const = 0; | 163 virtual bool IsSpeaking() const = 0; |
164 // Stops speaking, if it is currently in progress. | 164 // Stops speaking, if it is currently in progress. |
165 virtual void StopSpeaking() = 0; | 165 virtual void StopSpeaking() = 0; |
166 #endif // defined(OS_MACOSX) | 166 #endif // defined(OS_MACOSX) |
167 }; | 167 }; |
168 | 168 |
169 } // namespace content | 169 } // namespace content |
170 | 170 |
171 #endif // CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ | 171 #endif // CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ |
OLD | NEW |