OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "content/child/runtime_features.h" | 5 #include "content/child/runtime_features.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "content/public/common/content_switches.h" | 8 #include "content/public/common/content_switches.h" |
9 #include "third_party/WebKit/public/web/WebRuntimeFeatures.h" | 9 #include "third_party/WebKit/public/web/WebRuntimeFeatures.h" |
10 | 10 |
(...skipping 14 matching lines...) Expand all Loading... |
25 | 25 |
26 #if defined(OS_ANDROID) | 26 #if defined(OS_ANDROID) |
27 bool enable_webaudio = false; | 27 bool enable_webaudio = false; |
28 #if defined(ARCH_CPU_ARMEL) | 28 #if defined(ARCH_CPU_ARMEL) |
29 enable_webaudio = | 29 enable_webaudio = |
30 ((android_getCpuFeatures() & ANDROID_CPU_ARM_FEATURE_NEON) != 0); | 30 ((android_getCpuFeatures() & ANDROID_CPU_ARM_FEATURE_NEON) != 0); |
31 #endif | 31 #endif |
32 WebRuntimeFeatures::enableWebAudio(enable_webaudio); | 32 WebRuntimeFeatures::enableWebAudio(enable_webaudio); |
33 // Android does not support the Gamepad API. | 33 // Android does not support the Gamepad API. |
34 WebRuntimeFeatures::enableGamepad(false); | 34 WebRuntimeFeatures::enableGamepad(false); |
35 // input[type=week] in Android is incomplete. crbug.com/135938 | |
36 WebRuntimeFeatures::enableInputTypeWeek(false); | |
37 // Android does not have support for PagePopup | 35 // Android does not have support for PagePopup |
38 WebRuntimeFeatures::enablePagePopup(false); | 36 WebRuntimeFeatures::enablePagePopup(false); |
39 // datalist on Android is not enabled | 37 // datalist on Android is not enabled |
40 WebRuntimeFeatures::enableDataListElement(false); | 38 WebRuntimeFeatures::enableDataListElement(false); |
41 #endif | 39 #endif |
42 } | 40 } |
43 | 41 |
44 void SetRuntimeFeaturesDefaultsAndUpdateFromArgs( | 42 void SetRuntimeFeaturesDefaultsAndUpdateFromArgs( |
45 const CommandLine& command_line) { | 43 const CommandLine& command_line) { |
46 WebRuntimeFeatures::enableStableFeatures(true); | 44 WebRuntimeFeatures::enableStableFeatures(true); |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 WebRuntimeFeatures::enableExperimentalCanvasFeatures(true); | 118 WebRuntimeFeatures::enableExperimentalCanvasFeatures(true); |
121 | 119 |
122 if (command_line.HasSwitch(switches::kEnableSpeechSynthesis)) | 120 if (command_line.HasSwitch(switches::kEnableSpeechSynthesis)) |
123 WebRuntimeFeatures::enableSpeechSynthesis(true); | 121 WebRuntimeFeatures::enableSpeechSynthesis(true); |
124 | 122 |
125 if (command_line.HasSwitch(switches::kEnableWebGLDraftExtensions)) | 123 if (command_line.HasSwitch(switches::kEnableWebGLDraftExtensions)) |
126 WebRuntimeFeatures::enableWebGLDraftExtensions(true); | 124 WebRuntimeFeatures::enableWebGLDraftExtensions(true); |
127 } | 125 } |
128 | 126 |
129 } // namespace content | 127 } // namespace content |
OLD | NEW |