Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(268)

Side by Side Diff: content/child/runtime_features.cc

Issue 950723003: [Push] Enable PushManager.hasPermission() in browser tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2311
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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
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
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
OLDNEW
« no previous file with comments | « content/browser/renderer_host/render_process_host_impl.cc ('k') | content/public/common/content_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698