| 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 ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_BUBBLE_H_ | 5 #ifndef ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_BUBBLE_H_ |
| 6 #define ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_BUBBLE_H_ | 6 #define ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_BUBBLE_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <vector> | 10 #include <vector> |
| 11 | 11 |
| 12 #include "ash/common/login_status.h" | 12 #include "ash/common/login_status.h" |
| 13 #include "ash/common/system/tray/system_tray_item.h" | 13 #include "ash/common/system/tray/system_tray_item.h" |
| 14 #include "base/macros.h" | 14 #include "base/macros.h" |
| 15 #include "base/timer/timer.h" | 15 #include "base/timer/timer.h" |
| 16 #include "ui/views/bubble/tray_bubble_view.h" | 16 #include "ui/views/bubble/tray_bubble_view.h" |
| 17 | 17 |
| 18 namespace ash { | 18 namespace ash { |
| 19 class SystemTray; | 19 class SystemTray; |
| 20 class SystemTrayItem; | 20 class SystemTrayItem; |
| 21 | 21 |
| 22 class SystemTrayBubble { | 22 class SystemTrayBubble { |
| 23 public: | 23 public: |
| 24 enum BubbleType { | 24 enum BubbleType { BUBBLE_TYPE_DEFAULT, BUBBLE_TYPE_DETAILED }; |
| 25 BUBBLE_TYPE_DEFAULT, | |
| 26 BUBBLE_TYPE_DETAILED, | |
| 27 BUBBLE_TYPE_NOTIFICATION | |
| 28 }; | |
| 29 | 25 |
| 30 SystemTrayBubble(ash::SystemTray* tray, | 26 SystemTrayBubble(ash::SystemTray* tray, |
| 31 const std::vector<ash::SystemTrayItem*>& items, | 27 const std::vector<ash::SystemTrayItem*>& items, |
| 32 BubbleType bubble_type); | 28 BubbleType bubble_type); |
| 33 virtual ~SystemTrayBubble(); | 29 virtual ~SystemTrayBubble(); |
| 34 | 30 |
| 35 // Change the items displayed in the bubble. | 31 // Change the items displayed in the bubble. |
| 36 void UpdateView(const std::vector<ash::SystemTrayItem*>& items, | 32 void UpdateView(const std::vector<ash::SystemTrayItem*>& items, |
| 37 BubbleType bubble_type); | 33 BubbleType bubble_type); |
| 38 | 34 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 81 | 77 |
| 82 int autoclose_delay_; | 78 int autoclose_delay_; |
| 83 base::OneShotTimer autoclose_; | 79 base::OneShotTimer autoclose_; |
| 84 | 80 |
| 85 DISALLOW_COPY_AND_ASSIGN(SystemTrayBubble); | 81 DISALLOW_COPY_AND_ASSIGN(SystemTrayBubble); |
| 86 }; | 82 }; |
| 87 | 83 |
| 88 } // namespace ash | 84 } // namespace ash |
| 89 | 85 |
| 90 #endif // ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_BUBBLE_H_ | 86 #endif // ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_BUBBLE_H_ |
| OLD | NEW |