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

Side by Side Diff: ui/views/corewm/tooltip.h

Issue 1608733002: Remove ui/gfx/screen_type_delegate.h (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@metro-mode-4
Patch Set: and another rebase Created 4 years, 10 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 unified diff | Download patch
« no previous file with comments | « ui/views/controls/textfield/textfield.cc ('k') | ui/views/corewm/tooltip_aura.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 UI_VIEWS_COREWM_TOOLTIP_H_ 5 #ifndef UI_VIEWS_COREWM_TOOLTIP_H_
6 #define UI_VIEWS_COREWM_TOOLTIP_H_ 6 #define UI_VIEWS_COREWM_TOOLTIP_H_
7 7
8 #include "base/strings/string16.h" 8 #include "base/strings/string16.h"
9 #include "ui/views/views_export.h" 9 #include "ui/views/views_export.h"
10 10
11 namespace aura { 11 namespace aura {
12 class Window; 12 class Window;
13 } 13 }
14 14
15 namespace gfx { 15 namespace gfx {
16 class Point; 16 class Point;
17 } 17 }
18 18
19 namespace views { 19 namespace views {
20 namespace corewm { 20 namespace corewm {
21 21
22 // Tooltip is responsible for showing the tooltip in an appropriate manner. 22 // Tooltip is responsible for showing the tooltip in an appropriate manner.
23 // Tooltip is used by TooltipController. 23 // Tooltip is used by TooltipController.
24 class VIEWS_EXPORT Tooltip { 24 class VIEWS_EXPORT Tooltip {
25 public: 25 public:
26 virtual ~Tooltip() {} 26 virtual ~Tooltip() {}
27 27
28 // Returns the max width of the tooltip when shown at the specified location. 28 // Returns the max width of the tooltip when shown at the specified location.
29 virtual int GetMaxWidth(const gfx::Point& location, 29 virtual int GetMaxWidth(const gfx::Point& location) const = 0;
30 aura::Window* context) const = 0;
31 30
32 // Updates the text on the tooltip and resizes to fit. 31 // Updates the text on the tooltip and resizes to fit.
33 virtual void SetText(aura::Window* window, 32 virtual void SetText(aura::Window* window,
34 const base::string16& tooltip_text, 33 const base::string16& tooltip_text,
35 const gfx::Point& location) = 0; 34 const gfx::Point& location) = 0;
36 35
37 // Shows the tooltip at the specified location (in screen coordinates). 36 // Shows the tooltip at the specified location (in screen coordinates).
38 virtual void Show() = 0; 37 virtual void Show() = 0;
39 38
40 // Hides the tooltip. 39 // Hides the tooltip.
41 virtual void Hide() = 0; 40 virtual void Hide() = 0;
42 41
43 // Is the tooltip visibile? 42 // Is the tooltip visibile?
44 virtual bool IsVisible() = 0; 43 virtual bool IsVisible() = 0;
45 }; 44 };
46 45
47 } // namespace corewm 46 } // namespace corewm
48 } // namespace views 47 } // namespace views
49 48
50 #endif // UI_VIEWS_COREWM_TOOLTIP_H_ 49 #endif // UI_VIEWS_COREWM_TOOLTIP_H_
OLDNEW
« no previous file with comments | « ui/views/controls/textfield/textfield.cc ('k') | ui/views/corewm/tooltip_aura.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698