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

Side by Side Diff: chrome/browser/about_flags.cc

Issue 10752006: Adding a field trial to enable speculative resource prefetching learning. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebasing for submit. Created 8 years, 5 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 (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 "chrome/browser/about_flags.h" 5 #include "chrome/browser/about_flags.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <iterator> 8 #include <iterator>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 829 matching lines...) Expand 10 before | Expand all | Expand 10 after
840 }, 840 },
841 #if defined(USE_ASH) 841 #if defined(USE_ASH)
842 { 842 {
843 "ash-debug-shortcuts", 843 "ash-debug-shortcuts",
844 IDS_FLAGS_DEBUG_SHORTCUTS_NAME, 844 IDS_FLAGS_DEBUG_SHORTCUTS_NAME,
845 IDS_FLAGS_DEBUG_SHORTCUTS_DESCRIPTION, 845 IDS_FLAGS_DEBUG_SHORTCUTS_DESCRIPTION,
846 kOsAll, 846 kOsAll,
847 SINGLE_VALUE_TYPE(ash::switches::kAshDebugShortcuts), 847 SINGLE_VALUE_TYPE(ash::switches::kAshDebugShortcuts),
848 }, 848 },
849 #endif 849 #endif
850 {
851 "enable-speculative-resource-prefetching",
852 IDS_FLAGS_ENABLE_SPECULATIVE_RESOURCE_PREFETCHING_NAME,
853 IDS_FLAGS_ENABLE_SPECULATIVE_RESOURCE_PREFETCHING_DESCRIPTION,
854 kOsAll,
855 SINGLE_VALUE_TYPE(switches::kEnableSpeculativeResourcePrefetching),
856 },
857 }; 850 };
858 851
859 const Experiment* experiments = kExperiments; 852 const Experiment* experiments = kExperiments;
860 size_t num_experiments = arraysize(kExperiments); 853 size_t num_experiments = arraysize(kExperiments);
861 854
862 // Stores and encapsulates the little state that about:flags has. 855 // Stores and encapsulates the little state that about:flags has.
863 class FlagsState { 856 class FlagsState {
864 public: 857 public:
865 FlagsState() : needs_restart_(false) {} 858 FlagsState() : needs_restart_(false) {}
866 void ConvertFlagsToSwitches(PrefService* prefs, CommandLine* command_line); 859 void ConvertFlagsToSwitches(PrefService* prefs, CommandLine* command_line);
(...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after
1282 } 1275 }
1283 1276
1284 const Experiment* GetExperiments(size_t* count) { 1277 const Experiment* GetExperiments(size_t* count) {
1285 *count = num_experiments; 1278 *count = num_experiments;
1286 return experiments; 1279 return experiments;
1287 } 1280 }
1288 1281
1289 } // namespace testing 1282 } // namespace testing
1290 1283
1291 } // namespace about_flags 1284 } // namespace about_flags
OLDNEW
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | chrome/browser/predictors/resource_prefetch_predictor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698