| 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 "webkit/glue/webthemeengine_impl_android.h" | 5 #include "webkit/glue/webthemeengine_impl_android.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "skia/ext/platform_canvas.h" | 8 #include "skia/ext/platform_canvas.h" |
| 9 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebRect.h" | 9 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebRect.h" |
| 10 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebSize.h" | 10 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebSize.h" |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 extra_params->button.indeterminate; | 100 extra_params->button.indeterminate; |
| 101 break; | 101 break; |
| 102 case WebThemeEngine::PartRadio: | 102 case WebThemeEngine::PartRadio: |
| 103 native_theme_extra_params->button.checked = extra_params->button.checked; | 103 native_theme_extra_params->button.checked = extra_params->button.checked; |
| 104 break; | 104 break; |
| 105 case WebThemeEngine::PartButton: | 105 case WebThemeEngine::PartButton: |
| 106 native_theme_extra_params->button.is_default = | 106 native_theme_extra_params->button.is_default = |
| 107 extra_params->button.isDefault; | 107 extra_params->button.isDefault; |
| 108 native_theme_extra_params->button.has_border = | 108 native_theme_extra_params->button.has_border = |
| 109 extra_params->button.hasBorder; | 109 extra_params->button.hasBorder; |
| 110 // Native buttons have a different focus style. |
| 111 native_theme_extra_params->button.is_focused = false; |
| 110 native_theme_extra_params->button.background_color = | 112 native_theme_extra_params->button.background_color = |
| 111 extra_params->button.backgroundColor; | 113 extra_params->button.backgroundColor; |
| 112 break; | 114 break; |
| 113 case WebThemeEngine::PartTextField: | 115 case WebThemeEngine::PartTextField: |
| 114 native_theme_extra_params->text_field.is_text_area = | 116 native_theme_extra_params->text_field.is_text_area = |
| 115 extra_params->textField.isTextArea; | 117 extra_params->textField.isTextArea; |
| 116 native_theme_extra_params->text_field.is_listbox = | 118 native_theme_extra_params->text_field.is_listbox = |
| 117 extra_params->textField.isListbox; | 119 extra_params->textField.isListbox; |
| 118 native_theme_extra_params->text_field.background_color = | 120 native_theme_extra_params->text_field.background_color = |
| 119 extra_params->textField.backgroundColor; | 121 extra_params->textField.backgroundColor; |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 175 GetNativeThemeExtraParams( | 177 GetNativeThemeExtraParams( |
| 176 part, state, extra_params, &native_theme_extra_params); | 178 part, state, extra_params, &native_theme_extra_params); |
| 177 ui::NativeTheme::instance()->Paint( | 179 ui::NativeTheme::instance()->Paint( |
| 178 canvas, | 180 canvas, |
| 179 NativeThemePart(part), | 181 NativeThemePart(part), |
| 180 NativeThemeState(state), | 182 NativeThemeState(state), |
| 181 gfx::Rect(rect), | 183 gfx::Rect(rect), |
| 182 native_theme_extra_params); | 184 native_theme_extra_params); |
| 183 } | 185 } |
| 184 } // namespace webkit_glue | 186 } // namespace webkit_glue |
| OLD | NEW |