| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 CHROME_BROWSER_CHROMEOS_STATUS_POWER_MENU_BUTTON_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_STATUS_POWER_MENU_BUTTON_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_STATUS_POWER_MENU_BUTTON_H_ | 6 #define CHROME_BROWSER_CHROMEOS_STATUS_POWER_MENU_BUTTON_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "chrome/browser/chromeos/cros/power_library.h" | 9 #include "chrome/browser/chromeos/cros/power_library.h" |
| 10 #include "chrome/browser/chromeos/status/status_area_button.h" | 10 #include "chrome/browser/chromeos/status/status_area_button.h" |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 return NULL; | 46 return NULL; |
| 47 } | 47 } |
| 48 virtual bool IsEnabledAt(int index) const { return false; } | 48 virtual bool IsEnabledAt(int index) const { return false; } |
| 49 virtual ui::MenuModel* GetSubmenuModelAt(int index) const { return NULL; } | 49 virtual ui::MenuModel* GetSubmenuModelAt(int index) const { return NULL; } |
| 50 virtual void HighlightChangedTo(int index) {} | 50 virtual void HighlightChangedTo(int index) {} |
| 51 virtual void ActivatedAt(int index) {} | 51 virtual void ActivatedAt(int index) {} |
| 52 virtual void MenuWillShow() {} | 52 virtual void MenuWillShow() {} |
| 53 | 53 |
| 54 // PowerLibrary::Observer implementation. | 54 // PowerLibrary::Observer implementation. |
| 55 virtual void PowerChanged(PowerLibrary* obj); | 55 virtual void PowerChanged(PowerLibrary* obj); |
| 56 virtual void SystemResumed() {} |
| 56 | 57 |
| 57 int icon_id() const { return icon_id_; } | 58 int icon_id() const { return icon_id_; } |
| 58 | 59 |
| 59 protected: | 60 protected: |
| 60 virtual int icon_width() { return 26; } | 61 virtual int icon_width() { return 26; } |
| 61 | 62 |
| 62 private: | 63 private: |
| 63 // views::ViewMenuDelegate implementation. | 64 // views::ViewMenuDelegate implementation. |
| 64 virtual void RunMenu(views::View* source, const gfx::Point& pt); | 65 virtual void RunMenu(views::View* source, const gfx::Point& pt); |
| 65 | 66 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 83 // The power menu. This needs to be initialized last since it calls into | 84 // The power menu. This needs to be initialized last since it calls into |
| 84 // GetLabelAt() during construction. | 85 // GetLabelAt() during construction. |
| 85 views::Menu2 power_menu_; | 86 views::Menu2 power_menu_; |
| 86 | 87 |
| 87 DISALLOW_COPY_AND_ASSIGN(PowerMenuButton); | 88 DISALLOW_COPY_AND_ASSIGN(PowerMenuButton); |
| 88 }; | 89 }; |
| 89 | 90 |
| 90 } // namespace chromeos | 91 } // namespace chromeos |
| 91 | 92 |
| 92 #endif // CHROME_BROWSER_CHROMEOS_STATUS_POWER_MENU_BUTTON_H_ | 93 #endif // CHROME_BROWSER_CHROMEOS_STATUS_POWER_MENU_BUTTON_H_ |
| OLD | NEW |