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

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

Issue 2798033002: [Doodle] Allow overriding the API URL via a fieldtrial param (Closed)
Patch Set: rebase Created 3 years, 8 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
« no previous file with comments | « no previous file | chrome/browser/doodle/doodle_service_factory.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 <iterator> 7 #include <iterator>
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <utility> 10 #include <utility>
(...skipping 735 matching lines...) Expand 10 before | Expand all | Expand 10 after
746 kAutofillCreditCardLastUsedDateFeatureVariationExpDate[] = { 746 kAutofillCreditCardLastUsedDateFeatureVariationExpDate[] = {
747 {"show_expiration_date", "true"}}; 747 {"show_expiration_date", "true"}};
748 748
749 const FeatureEntry::FeatureVariation 749 const FeatureEntry::FeatureVariation
750 kAutofillCreditCardLastUsedDateFeatureVariations[] = { 750 kAutofillCreditCardLastUsedDateFeatureVariations[] = {
751 {"Display expiration date", 751 {"Display expiration date",
752 kAutofillCreditCardLastUsedDateFeatureVariationExpDate, 752 kAutofillCreditCardLastUsedDateFeatureVariationExpDate,
753 arraysize(kAutofillCreditCardLastUsedDateFeatureVariationExpDate), 753 arraysize(kAutofillCreditCardLastUsedDateFeatureVariationExpDate),
754 nullptr}}; 754 nullptr}};
755 755
756 #if defined(OS_ANDROID)
757 const FeatureEntry::FeatureParam kUseNewDoodleApiTest0[] = {
758 {"doodle_override_url",
759 "https://www.gstatic.com/chrome/ntp/doodle_test/android0.json"}};
760 const FeatureEntry::FeatureParam kUseNewDoodleApiTest1[] = {
761 {"doodle_override_url",
762 "https://www.gstatic.com/chrome/ntp/doodle_test/android1.json"}};
763 const FeatureEntry::FeatureParam kUseNewDoodleApiTest2[] = {
764 {"doodle_override_url",
765 "https://www.gstatic.com/chrome/ntp/doodle_test/android2.json"}};
766 const FeatureEntry::FeatureParam kUseNewDoodleApiTest3[] = {
767 {"doodle_override_url",
768 "https://www.gstatic.com/chrome/ntp/doodle_test/android3.json"}};
769 const FeatureEntry::FeatureParam kUseNewDoodleApiTest4[] = {
770 {"doodle_override_url",
771 "https://www.gstatic.com/chrome/ntp/doodle_test/android4.json"}};
772 const FeatureEntry::FeatureParam kUseNewDoodleApiTest5[] = {
773 {"doodle_override_url",
774 "https://www.gstatic.com/chrome/ntp/doodle_test/android5.json"}};
775 const FeatureEntry::FeatureParam kUseNewDoodleApiTest6[] = {
776 {"doodle_override_url",
777 "https://www.gstatic.com/chrome/ntp/doodle_test/android6.json"}};
778 const FeatureEntry::FeatureParam kUseNewDoodleApiTest7[] = {
779 {"doodle_override_url",
780 "https://www.gstatic.com/chrome/ntp/doodle_test/android7.json"}};
781 const FeatureEntry::FeatureParam kUseNewDoodleApiTest8[] = {
782 {"doodle_override_url",
783 "https://www.gstatic.com/chrome/ntp/doodle_test/android8.json"}};
784
785 const FeatureEntry::FeatureVariation kUseNewDoodleApiVariations[] = {
786 {"(force test doodle 0)", kUseNewDoodleApiTest0,
787 arraysize(kUseNewDoodleApiTest0), nullptr},
788 {"(force test doodle 1)", kUseNewDoodleApiTest1,
789 arraysize(kUseNewDoodleApiTest1), nullptr},
790 {"(force test doodle 2)", kUseNewDoodleApiTest2,
791 arraysize(kUseNewDoodleApiTest2), nullptr},
792 {"(force test doodle 3)", kUseNewDoodleApiTest3,
793 arraysize(kUseNewDoodleApiTest3), nullptr},
794 {"(force test doodle 4)", kUseNewDoodleApiTest4,
795 arraysize(kUseNewDoodleApiTest4), nullptr},
796 {"(force test doodle 5)", kUseNewDoodleApiTest5,
797 arraysize(kUseNewDoodleApiTest5), nullptr},
798 {"(force test doodle 6)", kUseNewDoodleApiTest6,
799 arraysize(kUseNewDoodleApiTest6), nullptr},
800 {"(force test doodle 7)", kUseNewDoodleApiTest7,
801 arraysize(kUseNewDoodleApiTest7), nullptr},
802 {"(force test doodle 8)", kUseNewDoodleApiTest8,
803 arraysize(kUseNewDoodleApiTest8), nullptr}};
804 #endif // OS_ANDROID
805
756 const FeatureEntry::FeatureParam kDelayNavigation5SecondDelay[] = { 806 const FeatureEntry::FeatureParam kDelayNavigation5SecondDelay[] = {
757 {DelayNavigationThrottle::kParamDelayNavigationDurationMillis, "5000"}, 807 {DelayNavigationThrottle::kParamDelayNavigationDurationMillis, "5000"},
758 {DelayNavigationThrottle::kParamDelayNavigationProbability, "1"}}; 808 {DelayNavigationThrottle::kParamDelayNavigationProbability, "1"}};
759 809
760 const FeatureEntry::FeatureParam kDelayNavigation5SecondDelay25Percent[] = { 810 const FeatureEntry::FeatureParam kDelayNavigation5SecondDelay25Percent[] = {
761 {DelayNavigationThrottle::kParamDelayNavigationDurationMillis, "5000"}, 811 {DelayNavigationThrottle::kParamDelayNavigationDurationMillis, "5000"},
762 {DelayNavigationThrottle::kParamDelayNavigationProbability, "0.25"}}; 812 {DelayNavigationThrottle::kParamDelayNavigationProbability, "0.25"}};
763 813
764 const FeatureEntry::FeatureParam kDelayNavigation5SecondDelayRandomize[] = { 814 const FeatureEntry::FeatureParam kDelayNavigation5SecondDelayRandomize[] = {
765 {DelayNavigationThrottle::kParamDelayNavigationDurationMillis, "5000"}, 815 {DelayNavigationThrottle::kParamDelayNavigationDurationMillis, "5000"},
(...skipping 1729 matching lines...) Expand 10 before | Expand all | Expand 10 after
2495 flag_descriptions::kMojoLoadingDescription, kOsAll, 2545 flag_descriptions::kMojoLoadingDescription, kOsAll,
2496 FEATURE_VALUE_TYPE(features::kLoadingWithMojo)}, 2546 FEATURE_VALUE_TYPE(features::kLoadingWithMojo)},
2497 2547
2498 #if defined(OS_CHROMEOS) 2548 #if defined(OS_CHROMEOS)
2499 {"force-tablet-mode", flag_descriptions::kForceTabletModeName, 2549 {"force-tablet-mode", flag_descriptions::kForceTabletModeName,
2500 flag_descriptions::kForceTabletModeDescription, kOsCrOS, 2550 flag_descriptions::kForceTabletModeDescription, kOsCrOS,
2501 MULTI_VALUE_TYPE(kAshForceTabletModeChoices)}, 2551 MULTI_VALUE_TYPE(kAshForceTabletModeChoices)},
2502 #endif // OS_CHROMEOS 2552 #endif // OS_CHROMEOS
2503 2553
2504 #if defined(OS_ANDROID) 2554 #if defined(OS_ANDROID)
2505 {"use-new-doodle-api", flag_descriptions::kUseNewDoodleApiName, 2555 {"use-new-doodle-api", flag_descriptions::kUseNewDoodleApiName,
sfiera 2017/04/05 15:22:13 So this flag doesn't exist on Desktop, even though
Marc Treib 2017/04/05 15:33:59 Eventually, but not yet. When we start working on
2506 flag_descriptions::kUseNewDoodleApiDescription, kOsAndroid, 2556 flag_descriptions::kUseNewDoodleApiDescription, kOsAndroid,
2507 FEATURE_VALUE_TYPE(chrome::android::kUseNewDoodleApi)}, 2557 FEATURE_WITH_PARAMS_VALUE_TYPE(chrome::android::kUseNewDoodleApi,
2558 kUseNewDoodleApiVariations,
2559 "UseNewDoodleApi")},
sfiera 2017/04/05 15:22:13 kUseNewDoodleApi.name?
Marc Treib 2017/04/05 15:33:59 Done.
2508 #endif // OS_ANDROID 2560 #endif // OS_ANDROID
2509 2561
2510 {"delay-navigation", flag_descriptions::kDelayNavigationName, 2562 {"delay-navigation", flag_descriptions::kDelayNavigationName,
2511 flag_descriptions::kDelayNavigationDescription, kOsAll, 2563 flag_descriptions::kDelayNavigationDescription, kOsAll,
2512 FEATURE_WITH_PARAMS_VALUE_TYPE(kDelayNavigationFeature, 2564 FEATURE_WITH_PARAMS_VALUE_TYPE(kDelayNavigationFeature,
2513 kDelayNavigationFeatureVariations, 2565 kDelayNavigationFeatureVariations,
2514 "DelayNavigation")}, 2566 "DelayNavigation")},
2515 2567
2516 #if defined(OS_ANDROID) 2568 #if defined(OS_ANDROID)
2517 {"enable-custom-context-menu", 2569 {"enable-custom-context-menu",
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
2721 const base::HistogramBase::Sample kBadSwitchFormatHistogramId = 0; 2773 const base::HistogramBase::Sample kBadSwitchFormatHistogramId = 0;
2722 2774
2723 const FeatureEntry* GetFeatureEntries(size_t* count) { 2775 const FeatureEntry* GetFeatureEntries(size_t* count) {
2724 *count = arraysize(kFeatureEntries); 2776 *count = arraysize(kFeatureEntries);
2725 return kFeatureEntries; 2777 return kFeatureEntries;
2726 } 2778 }
2727 2779
2728 } // namespace testing 2780 } // namespace testing
2729 2781
2730 } // namespace about_flags 2782 } // namespace about_flags
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/doodle/doodle_service_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698