| 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 "ui/native_theme/common_theme.h" | 5 #include "ui/native_theme/common_theme.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/memory/ptr_util.h" | 8 #include "base/memory/ptr_util.h" |
| 9 #include "third_party/skia/include/core/SkCanvas.h" | 9 #include "third_party/skia/include/core/SkCanvas.h" |
| 10 #include "ui/base/material_design/material_design_controller.h" | 10 #include "ui/base/material_design/material_design_controller.h" |
| (...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 205 case NativeTheme::kColorId_TextfieldDefaultBackground: | 205 case NativeTheme::kColorId_TextfieldDefaultBackground: |
| 206 return kTextfieldDefaultBackground; | 206 return kTextfieldDefaultBackground; |
| 207 case NativeTheme::kColorId_TextfieldReadOnlyColor: | 207 case NativeTheme::kColorId_TextfieldReadOnlyColor: |
| 208 return kTextfieldReadOnlyColor; | 208 return kTextfieldReadOnlyColor; |
| 209 case NativeTheme::kColorId_TextfieldReadOnlyBackground: | 209 case NativeTheme::kColorId_TextfieldReadOnlyBackground: |
| 210 return kTextfieldReadOnlyBackground; | 210 return kTextfieldReadOnlyBackground; |
| 211 case NativeTheme::kColorId_TextfieldSelectionColor: | 211 case NativeTheme::kColorId_TextfieldSelectionColor: |
| 212 return kTextfieldSelectionColor; | 212 return kTextfieldSelectionColor; |
| 213 case NativeTheme::kColorId_TextfieldSelectionBackgroundFocused: | 213 case NativeTheme::kColorId_TextfieldSelectionBackgroundFocused: |
| 214 return kTextfieldSelectionBackgroundFocused; | 214 return kTextfieldSelectionBackgroundFocused; |
| 215 case NativeTheme::kColorId_TextfieldSelectionBackgroundUnfocused: |
| 216 return kTextfieldSelectionBackgroundFocused; |
| 215 | 217 |
| 216 // Tooltip | 218 // Tooltip |
| 217 case NativeTheme::kColorId_TooltipBackground: | 219 case NativeTheme::kColorId_TooltipBackground: |
| 218 return kTooltipBackground; | 220 return kTooltipBackground; |
| 219 case NativeTheme::kColorId_TooltipText: | 221 case NativeTheme::kColorId_TooltipText: |
| 220 return kTooltipTextColor; | 222 return kTooltipTextColor; |
| 221 | 223 |
| 222 // Tree | 224 // Tree |
| 223 case NativeTheme::kColorId_TreeBackground: | 225 case NativeTheme::kColorId_TreeBackground: |
| 224 return kTreeBackground; | 226 return kTreeBackground; |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 336 } | 338 } |
| 337 if (menu_item.corner_radius > 0) { | 339 if (menu_item.corner_radius > 0) { |
| 338 const SkScalar radius = SkIntToScalar(menu_item.corner_radius); | 340 const SkScalar radius = SkIntToScalar(menu_item.corner_radius); |
| 339 canvas->drawRoundRect(gfx::RectToSkRect(rect), radius, radius, paint); | 341 canvas->drawRoundRect(gfx::RectToSkRect(rect), radius, radius, paint); |
| 340 return; | 342 return; |
| 341 } | 343 } |
| 342 canvas->drawRect(gfx::RectToSkRect(rect), paint); | 344 canvas->drawRect(gfx::RectToSkRect(rect), paint); |
| 343 } | 345 } |
| 344 | 346 |
| 345 } // namespace ui | 347 } // namespace ui |
| OLD | NEW |