OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "views/controls/label.h" | 5 #include "views/controls/label.h" |
6 | 6 |
7 #include <math.h> | 7 #include <math.h> |
8 #include <limits> | 8 #include <limits> |
9 | 9 |
10 #include "app/gfx/canvas.h" | 10 #include "app/gfx/canvas.h" |
11 #include "app/gfx/color_utils.h" | 11 #include "app/gfx/color_utils.h" |
12 #include "app/gfx/font.h" | 12 #include "app/gfx/font.h" |
13 #include "app/gfx/insets.h" | 13 #include "app/gfx/insets.h" |
14 #include "app/gfx/text_elider.h" | 14 #include "app/gfx/text_elider.h" |
15 #include "app/l10n_util.h" | 15 #include "app/l10n_util.h" |
16 #include "app/resource_bundle.h" | 16 #include "app/resource_bundle.h" |
17 #include "base/logging.h" | 17 #include "base/logging.h" |
18 #include "base/string_util.h" | 18 #include "base/utf_string_conversions.h" |
19 #include "views/background.h" | 19 #include "views/background.h" |
20 | 20 |
21 namespace views { | 21 namespace views { |
22 | 22 |
23 // static | 23 // static |
24 const char Label::kViewClassName[] = "views/Label"; | 24 const char Label::kViewClassName[] = "views/Label"; |
25 SkColor Label::kEnabledColor, Label::kDisabledColor; | 25 SkColor Label::kEnabledColor, Label::kDisabledColor; |
26 | 26 |
27 static const int kFocusBorderPadding = 1; | 27 static const int kFocusBorderPadding = 1; |
28 | 28 |
(...skipping 475 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
504 } | 504 } |
505 | 505 |
506 bool Label::GetAccessibleState(AccessibilityTypes::State* state) { | 506 bool Label::GetAccessibleState(AccessibilityTypes::State* state) { |
507 DCHECK(state); | 507 DCHECK(state); |
508 | 508 |
509 *state = AccessibilityTypes::STATE_READONLY; | 509 *state = AccessibilityTypes::STATE_READONLY; |
510 return true; | 510 return true; |
511 } | 511 } |
512 | 512 |
513 } // namespace views | 513 } // namespace views |
OLD | NEW |