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

Side by Side Diff: ui/views/widget/tooltip_manager.h

Issue 25478006: Nukes some dead TooltipManager code (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Nuke field Created 7 years, 2 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_WIDGET_TOOLTIP_MANAGER_H_ 5 #ifndef UI_VIEWS_WIDGET_TOOLTIP_MANAGER_H_
6 #define UI_VIEWS_WIDGET_TOOLTIP_MANAGER_H_ 6 #define UI_VIEWS_WIDGET_TOOLTIP_MANAGER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 28 matching lines...) Expand all
39 39
40 TooltipManager() {} 40 TooltipManager() {}
41 virtual ~TooltipManager() {} 41 virtual ~TooltipManager() {}
42 42
43 // Notification that the view hierarchy has changed in some way. 43 // Notification that the view hierarchy has changed in some way.
44 virtual void UpdateTooltip() = 0; 44 virtual void UpdateTooltip() = 0;
45 45
46 // Invoked when the tooltip text changes for the specified views. 46 // Invoked when the tooltip text changes for the specified views.
47 virtual void TooltipTextChanged(View* view) = 0; 47 virtual void TooltipTextChanged(View* view) = 0;
48 48
49 // Invoked when toolbar icon gets focus.
50 virtual void ShowKeyboardTooltip(View* view) = 0;
51
52 // Invoked when toolbar loses focus.
53 virtual void HideKeyboardTooltip() = 0;
54
55 protected: 49 protected:
56 // Trims the tooltip to fit, setting |text| to the clipped result, 50 // Trims the tooltip to fit, setting |text| to the clipped result,
57 // |max_width| to the width (in pixels) of the clipped text and |line_count| 51 // |max_width| to the width (in pixels) of the clipped text and |line_count|
58 // to the number of lines of text in the tooltip. |x| and |y| give the 52 // to the number of lines of text in the tooltip. |x| and |y| give the
59 // location of the tooltip in screen coordinates. |context| is used to 53 // location of the tooltip in screen coordinates. |context| is used to
60 // determine which gfx::Screen should be used. 54 // determine which gfx::Screen should be used.
61 static void TrimTooltipToFit(string16* text, 55 static void TrimTooltipToFit(string16* text,
62 int* max_width, 56 int* max_width,
63 int* line_count, 57 int* line_count,
64 int x, 58 int x,
65 int y, 59 int y,
66 gfx::NativeView context); 60 gfx::NativeView context);
67 }; 61 };
68 62
69 } // namespace views 63 } // namespace views
70 64
71 #endif // UI_VIEWS_WIDGET_TOOLTIP_MANAGER_H_ 65 #endif // UI_VIEWS_WIDGET_TOOLTIP_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698