OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_CLOCK_MENU_BUTTON_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_STATUS_CLOCK_MENU_BUTTON_H_ |
6 #define CHROME_BROWSER_CHROMEOS_STATUS_CLOCK_MENU_BUTTON_H_ | 6 #define CHROME_BROWSER_CHROMEOS_STATUS_CLOCK_MENU_BUTTON_H_ |
7 | 7 |
8 #include "base/scoped_ptr.h" | 8 #include "base/scoped_ptr.h" |
9 #include "base/timer.h" | 9 #include "base/timer.h" |
10 #include "chrome/browser/pref_member.h" | 10 #include "chrome/browser/pref_member.h" |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 base::OneShotTimer<ClockMenuButton> timer_; | 68 base::OneShotTimer<ClockMenuButton> timer_; |
69 scoped_ptr<icu::Calendar> cal_; | 69 scoped_ptr<icu::Calendar> cal_; |
70 | 70 |
71 // The clock menu. | 71 // The clock menu. |
72 // NOTE: we use a scoped_ptr here as menu calls into 'this' from the | 72 // NOTE: we use a scoped_ptr here as menu calls into 'this' from the |
73 // constructor. | 73 // constructor. |
74 scoped_ptr<views::Menu2> clock_menu_; | 74 scoped_ptr<views::Menu2> clock_menu_; |
75 | 75 |
76 StatusAreaHost* host_; | 76 StatusAreaHost* host_; |
77 | 77 |
| 78 // Variables to keep track of the max width of this view when there is 1 or 2 |
| 79 // digits in the hour time. |
| 80 int max_width_one_digit; |
| 81 int max_width_two_digit; |
| 82 |
78 // Preferences for this section: | 83 // Preferences for this section: |
79 StringPrefMember timezone_; | 84 StringPrefMember timezone_; |
80 | 85 |
81 DISALLOW_COPY_AND_ASSIGN(ClockMenuButton); | 86 DISALLOW_COPY_AND_ASSIGN(ClockMenuButton); |
82 }; | 87 }; |
83 | 88 |
84 } // namespace chromeos | 89 } // namespace chromeos |
85 | 90 |
86 #endif // CHROME_BROWSER_CHROMEOS_STATUS_CLOCK_MENU_BUTTON_H_ | 91 #endif // CHROME_BROWSER_CHROMEOS_STATUS_CLOCK_MENU_BUTTON_H_ |
OLD | NEW |