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/native_theme_android.h" | 5 #include "ui/native_theme/native_theme_android.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "ui/gfx/geometry/size.h" | 9 #include "ui/gfx/geometry/size.h" |
10 | 10 |
11 namespace ui { | 11 namespace ui { |
12 | 12 |
13 namespace { | 13 namespace { |
14 // These are the default dimensions of radio buttons and checkboxes on Android. | 14 // These are the default dimensions of radio buttons and checkboxes on Android. |
15 const int kCheckboxAndRadioWidth = 16; | 15 const int kCheckboxAndRadioWidth = 16; |
16 const int kCheckboxAndRadioHeight = 16; | 16 const int kCheckboxAndRadioHeight = 16; |
17 } | 17 } |
18 | 18 |
19 #if !defined(USE_AURA) | 19 #if !defined(USE_AURA) |
20 // static | 20 // static |
21 NativeTheme* NativeTheme::instance() { | 21 NativeTheme* NativeTheme::GetInstanceForWeb() { |
22 return NativeThemeAndroid::instance(); | 22 return NativeThemeAndroid::instance(); |
23 } | 23 } |
24 #endif | 24 #endif |
25 | 25 |
26 // static | 26 // static |
27 NativeThemeAndroid* NativeThemeAndroid::instance() { | 27 NativeThemeAndroid* NativeThemeAndroid::instance() { |
28 CR_DEFINE_STATIC_LOCAL(NativeThemeAndroid, s_native_theme, ()); | 28 CR_DEFINE_STATIC_LOCAL(NativeThemeAndroid, s_native_theme, ()); |
29 return &s_native_theme; | 29 return &s_native_theme; |
30 } | 30 } |
31 | 31 |
(...skipping 16 matching lines...) Expand all Loading... |
48 rect->bottom() - 1); | 48 rect->bottom() - 1); |
49 } | 49 } |
50 | 50 |
51 NativeThemeAndroid::NativeThemeAndroid() { | 51 NativeThemeAndroid::NativeThemeAndroid() { |
52 } | 52 } |
53 | 53 |
54 NativeThemeAndroid::~NativeThemeAndroid() { | 54 NativeThemeAndroid::~NativeThemeAndroid() { |
55 } | 55 } |
56 | 56 |
57 } // namespace ui | 57 } // namespace ui |
OLD | NEW |