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 <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/metrics/field_trial.h" | 10 #include "base/metrics/field_trial.h" |
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
184 if (command_line.HasSwitch(switches::kDisableSVG1DOM)) { | 184 if (command_line.HasSwitch(switches::kDisableSVG1DOM)) { |
185 WebRuntimeFeatures::enableSVG1DOM(false); | 185 WebRuntimeFeatures::enableSVG1DOM(false); |
186 } | 186 } |
187 | 187 |
188 if (command_line.HasSwitch(switches::kReducedReferrerGranularity)) | 188 if (command_line.HasSwitch(switches::kReducedReferrerGranularity)) |
189 WebRuntimeFeatures::enableReducedReferrerGranularity(true); | 189 WebRuntimeFeatures::enableReducedReferrerGranularity(true); |
190 | 190 |
191 if (command_line.HasSwitch(switches::kEnablePushMessagePayload)) | 191 if (command_line.HasSwitch(switches::kEnablePushMessagePayload)) |
192 WebRuntimeFeatures::enablePushMessagingData(true); | 192 WebRuntimeFeatures::enablePushMessagingData(true); |
193 | 193 |
| 194 if (command_line.HasSwitch(switches::kEnablePushMessagingHasPermission)) |
| 195 WebRuntimeFeatures::enablePushMessagingHasPermission(true); |
| 196 |
194 if (command_line.HasSwitch(switches::kDisableV8IdleTasks)) | 197 if (command_line.HasSwitch(switches::kDisableV8IdleTasks)) |
195 WebRuntimeFeatures::enableV8IdleTasks(false); | 198 WebRuntimeFeatures::enableV8IdleTasks(false); |
196 else | 199 else |
197 WebRuntimeFeatures::enableV8IdleTasks(true); | 200 WebRuntimeFeatures::enableV8IdleTasks(true); |
198 | 201 |
199 if (command_line.HasSwitch(switches::kEnableUnsafeES3APIs)) | 202 if (command_line.HasSwitch(switches::kEnableUnsafeES3APIs)) |
200 WebRuntimeFeatures::enableUnsafeES3APIs(true); | 203 WebRuntimeFeatures::enableUnsafeES3APIs(true); |
201 | 204 |
202 // Enable explicitly enabled features, and then disable explicitly disabled | 205 // Enable explicitly enabled features, and then disable explicitly disabled |
203 // ones. | 206 // ones. |
(...skipping 13 matching lines...) Expand all Loading... |
217 command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), ',', | 220 command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), ',', |
218 &disabled_features); | 221 &disabled_features); |
219 for (const std::string& feature : disabled_features) { | 222 for (const std::string& feature : disabled_features) { |
220 WebRuntimeFeatures::enableFeatureFromString( | 223 WebRuntimeFeatures::enableFeatureFromString( |
221 blink::WebString::fromLatin1(feature), false); | 224 blink::WebString::fromLatin1(feature), false); |
222 } | 225 } |
223 } | 226 } |
224 } | 227 } |
225 | 228 |
226 } // namespace content | 229 } // namespace content |
OLD | NEW |