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 "chrome/browser/about_flags.h" | 5 #include "chrome/browser/about_flags.h" |
6 | 6 |
7 #include <iterator> | 7 #include <iterator> |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <utility> | 10 #include <utility> |
(...skipping 2479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2490 kDelayNavigationFeatureVariations, | 2490 kDelayNavigationFeatureVariations, |
2491 "DelayNavigation")}, | 2491 "DelayNavigation")}, |
2492 | 2492 |
2493 #if defined(OS_ANDROID) | 2493 #if defined(OS_ANDROID) |
2494 {"enable-custom-context-menu", | 2494 {"enable-custom-context-menu", |
2495 flag_descriptions::kEnableCustomContextMenuName, | 2495 flag_descriptions::kEnableCustomContextMenuName, |
2496 flag_descriptions::kEnableCustomContextMenuDescription, kOsAndroid, | 2496 flag_descriptions::kEnableCustomContextMenuDescription, kOsAndroid, |
2497 FEATURE_VALUE_TYPE(chrome::android::kCustomContextMenu)}, | 2497 FEATURE_VALUE_TYPE(chrome::android::kCustomContextMenu)}, |
2498 #endif // OS_ANDROID | 2498 #endif // OS_ANDROID |
2499 | 2499 |
2500 {"enable-md-incognito-ntp", | |
2501 flag_descriptions::kEnableMaterialDesignIncognitoNTPName, | |
2502 flag_descriptions::kEnableMaterialDesignIncognitoNTPDescription, kOsAll, | |
2503 SINGLE_VALUE_TYPE(switches::kEnableMaterialDesignIncognitoNTP)}, | |
Dan Beam
2017/04/11 00:31:12
can we use a feature instead of a switch?
msramek
2017/04/11 19:04:26
Done. I also changed the OS to Desktop; I'll flip
| |
2504 | |
2500 // NOTE: Adding new command-line switches requires adding corresponding | 2505 // NOTE: Adding new command-line switches requires adding corresponding |
2501 // entries to enum "LoginCustomFlags" in histograms.xml. See note in | 2506 // entries to enum "LoginCustomFlags" in histograms.xml. See note in |
2502 // histograms.xml and don't forget to run AboutFlagsHistogramTest unit test. | 2507 // histograms.xml and don't forget to run AboutFlagsHistogramTest unit test. |
2503 }; | 2508 }; |
2504 | 2509 |
2505 class FlagsStateSingleton { | 2510 class FlagsStateSingleton { |
2506 public: | 2511 public: |
2507 FlagsStateSingleton() | 2512 FlagsStateSingleton() |
2508 : flags_state_(kFeatureEntries, arraysize(kFeatureEntries)) {} | 2513 : flags_state_(kFeatureEntries, arraysize(kFeatureEntries)) {} |
2509 ~FlagsStateSingleton() {} | 2514 ~FlagsStateSingleton() {} |
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2698 const base::HistogramBase::Sample kBadSwitchFormatHistogramId = 0; | 2703 const base::HistogramBase::Sample kBadSwitchFormatHistogramId = 0; |
2699 | 2704 |
2700 const FeatureEntry* GetFeatureEntries(size_t* count) { | 2705 const FeatureEntry* GetFeatureEntries(size_t* count) { |
2701 *count = arraysize(kFeatureEntries); | 2706 *count = arraysize(kFeatureEntries); |
2702 return kFeatureEntries; | 2707 return kFeatureEntries; |
2703 } | 2708 } |
2704 | 2709 |
2705 } // namespace testing | 2710 } // namespace testing |
2706 | 2711 |
2707 } // namespace about_flags | 2712 } // namespace about_flags |
OLD | NEW |