OLD | NEW |
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 ASH_SHELF_SHELF_TOOLTIP_MANAGER_H_ | 5 #ifndef ASH_SHELF_SHELF_TOOLTIP_MANAGER_H_ |
6 #define ASH_SHELF_SHELF_TOOLTIP_MANAGER_H_ | 6 #define ASH_SHELF_SHELF_TOOLTIP_MANAGER_H_ |
7 | 7 |
8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
9 #include "ash/shelf/shelf_layout_manager_observer.h" | 9 #include "ash/shelf/shelf_layout_manager_observer.h" |
10 #include "ash/shelf/shelf_types.h" | 10 #include "ash/shelf/shelf_types.h" |
11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
13 #include "base/strings/string16.h" | 13 #include "base/strings/string16.h" |
14 #include "ui/events/event_handler.h" | 14 #include "ui/events/event_handler.h" |
15 #include "ui/gfx/rect.h" | 15 #include "ui/gfx/rect.h" |
16 #include "ui/views/bubble/bubble_border.h" | 16 #include "ui/views/bubble/bubble_border.h" |
17 #include "ui/views/bubble/bubble_delegate.h" | 17 #include "ui/views/bubble/bubble_delegate.h" |
18 | 18 |
19 namespace base { | 19 namespace base { |
20 class Timer; | 20 class Timer; |
21 } | 21 } |
22 | 22 |
23 namespace views { | 23 namespace views { |
24 class BubbleDelegateView; | 24 class BubbleDelegateView; |
25 class Label; | 25 class Label; |
26 } | 26 } |
27 | 27 |
28 namespace ash { | 28 namespace ash { |
| 29 class ShelfView; |
| 30 class ShelfLayoutManager; |
| 31 |
29 namespace test { | 32 namespace test { |
30 class ShelfTooltipManagerTest; | 33 class ShelfTooltipManagerTest; |
31 class ShelfViewTest; | 34 class ShelfViewTest; |
32 } | 35 } |
33 | 36 |
34 namespace internal { | |
35 class ShelfView; | |
36 class ShelfLayoutManager; | |
37 | |
38 // ShelfTooltipManager manages the tooltip balloon poping up on shelf items. | 37 // ShelfTooltipManager manages the tooltip balloon poping up on shelf items. |
39 class ASH_EXPORT ShelfTooltipManager : public ui::EventHandler, | 38 class ASH_EXPORT ShelfTooltipManager : public ui::EventHandler, |
40 public ShelfLayoutManagerObserver { | 39 public ShelfLayoutManagerObserver { |
41 public: | 40 public: |
42 ShelfTooltipManager(ShelfLayoutManager* shelf_layout_manager, | 41 ShelfTooltipManager(ShelfLayoutManager* shelf_layout_manager, |
43 ShelfView* shelf_view); | 42 ShelfView* shelf_view); |
44 virtual ~ShelfTooltipManager(); | 43 virtual ~ShelfTooltipManager(); |
45 | 44 |
46 ShelfLayoutManager* shelf_layout_manager() { return shelf_layout_manager_; } | 45 ShelfLayoutManager* shelf_layout_manager() { return shelf_layout_manager_; } |
47 | 46 |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 scoped_ptr<base::Timer> timer_; | 107 scoped_ptr<base::Timer> timer_; |
109 | 108 |
110 ShelfLayoutManager* shelf_layout_manager_; | 109 ShelfLayoutManager* shelf_layout_manager_; |
111 ShelfView* shelf_view_; | 110 ShelfView* shelf_view_; |
112 | 111 |
113 base::WeakPtrFactory<ShelfTooltipManager> weak_factory_; | 112 base::WeakPtrFactory<ShelfTooltipManager> weak_factory_; |
114 | 113 |
115 DISALLOW_COPY_AND_ASSIGN(ShelfTooltipManager); | 114 DISALLOW_COPY_AND_ASSIGN(ShelfTooltipManager); |
116 }; | 115 }; |
117 | 116 |
118 } // namespace internal | |
119 } // namespace ash | 117 } // namespace ash |
120 | 118 |
121 #endif // ASH_SHELF_SHELF_TOOLTIP_MANAGER_H_ | 119 #endif // ASH_SHELF_SHELF_TOOLTIP_MANAGER_H_ |
OLD | NEW |