| 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/common/system/date/date_view.h" | 5 #include "ash/common/system/date/date_view.h" |
| 6 | 6 |
| 7 #include "ash/common/system/tray/system_tray_delegate.h" | 7 #include "ash/common/system/tray/system_tray_delegate.h" |
| 8 #include "ash/common/system/tray/tray_constants.h" | 8 #include "ash/common/system/tray/tray_constants.h" |
| 9 #include "ash/common/system/tray/tray_utils.h" | 9 #include "ash/common/system/tray/tray_utils.h" |
| 10 #include "ash/common/wm_shell.h" | 10 #include "ash/common/wm_shell.h" |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 simple_formatter.format(static_cast<UDate>(time.ToDoubleT() * 1000), | 67 simple_formatter.format(static_cast<UDate>(time.ToDoubleT() * 1000), |
| 68 date_string, status); | 68 date_string, status); |
| 69 DCHECK(U_SUCCESS(status)); | 69 DCHECK(U_SUCCESS(status)); |
| 70 return base::string16(date_string.getBuffer(), | 70 return base::string16(date_string.getBuffer(), |
| 71 static_cast<size_t>(date_string.length())); | 71 static_cast<size_t>(date_string.length())); |
| 72 } | 72 } |
| 73 | 73 |
| 74 views::Label* CreateLabel() { | 74 views::Label* CreateLabel() { |
| 75 views::Label* label = new views::Label; | 75 views::Label* label = new views::Label; |
| 76 label->SetHorizontalAlignment(gfx::ALIGN_LEFT); | 76 label->SetHorizontalAlignment(gfx::ALIGN_LEFT); |
| 77 label->SetBackgroundColor(SkColorSetARGB(0, 255, 255, 255)); | |
| 78 return label; | 77 return label; |
| 79 } | 78 } |
| 80 | 79 |
| 81 } // namespace | 80 } // namespace |
| 82 | 81 |
| 83 BaseDateTimeView::~BaseDateTimeView() { | 82 BaseDateTimeView::~BaseDateTimeView() { |
| 84 timer_.Stop(); | 83 timer_.Stop(); |
| 85 } | 84 } |
| 86 | 85 |
| 87 void BaseDateTimeView::UpdateText() { | 86 void BaseDateTimeView::UpdateText() { |
| (...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 328 } | 327 } |
| 329 | 328 |
| 330 void TimeView::SetupLabel(views::Label* label) { | 329 void TimeView::SetupLabel(views::Label* label) { |
| 331 label->set_owned_by_client(); | 330 label->set_owned_by_client(); |
| 332 SetupLabelForTray(label); | 331 SetupLabelForTray(label); |
| 333 label->SetElideBehavior(gfx::NO_ELIDE); | 332 label->SetElideBehavior(gfx::NO_ELIDE); |
| 334 } | 333 } |
| 335 | 334 |
| 336 } // namespace tray | 335 } // namespace tray |
| 337 } // namespace ash | 336 } // namespace ash |
| OLD | NEW |