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 #include "ash/system/monitor/tray_monitor.h" | 5 #include "ash/system/monitor/tray_monitor.h" |
6 | 6 |
7 #include "ash/system/tray/tray_item_view.h" | 7 #include "ash/system/tray/tray_item_view.h" |
8 #include "base/process_util.h" | 8 #include "base/process_util.h" |
9 #include "base/stringprintf.h" | 9 #include "base/stringprintf.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
11 #include "content/public/browser/gpu_data_manager.h" | 11 #include "content/public/browser/gpu_data_manager.h" |
12 #include "ui/base/text/bytes_formatting.h" | 12 #include "ui/base/text/bytes_formatting.h" |
| 13 #include "ui/views/border.h" |
13 #include "ui/views/controls/label.h" | 14 #include "ui/views/controls/label.h" |
14 #include "ui/views/border.h" | |
15 | 15 |
16 namespace { | 16 namespace { |
17 const int kRefreshTimeoutMs = 1000; | 17 const int kRefreshTimeoutMs = 1000; |
18 } | 18 } |
19 | 19 |
20 namespace ash { | 20 namespace ash { |
21 namespace internal { | 21 namespace internal { |
22 | 22 |
23 TrayMonitor::TrayMonitor(SystemTray* system_tray) | 23 TrayMonitor::TrayMonitor(SystemTray* system_tray) |
24 : SystemTrayItem(system_tray), | 24 : SystemTrayItem(system_tray), |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 UTF16ToUTF8(private_size).c_str(), | 88 UTF16ToUTF8(private_size).c_str(), |
89 UTF16ToUTF8(shared_size).c_str()); | 89 UTF16ToUTF8(shared_size).c_str()); |
90 label_->SetText(UTF8ToUTF16(output)); | 90 label_->SetText(UTF8ToUTF16(output)); |
91 refresh_timer_.Start(FROM_HERE, | 91 refresh_timer_.Start(FROM_HERE, |
92 base::TimeDelta::FromMilliseconds(kRefreshTimeoutMs), | 92 base::TimeDelta::FromMilliseconds(kRefreshTimeoutMs), |
93 this, &TrayMonitor::OnTimer); | 93 this, &TrayMonitor::OnTimer); |
94 } | 94 } |
95 | 95 |
96 } // namespace internal | 96 } // namespace internal |
97 } // namespace ash | 97 } // namespace ash |
OLD | NEW |