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

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

Issue 2696563002: [NTP::SectionOrder] Add EM oriented order. (Closed)
Patch Set: treib@ comment. Created 3 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 (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 481 matching lines...) Expand 10 before | Expand all | Expand 10 after
492 "disabled"}, 492 "disabled"},
493 {IDS_FLAGS_NTP_SWITCH_TO_EXISTING_TAB_MATCH_URL, 493 {IDS_FLAGS_NTP_SWITCH_TO_EXISTING_TAB_MATCH_URL,
494 switches::kNtpSwitchToExistingTab, "url"}, 494 switches::kNtpSwitchToExistingTab, "url"},
495 {IDS_FLAGS_NTP_SWITCH_TO_EXISTING_TAB_MATCH_HOST, 495 {IDS_FLAGS_NTP_SWITCH_TO_EXISTING_TAB_MATCH_HOST,
496 switches::kNtpSwitchToExistingTab, "host"}, 496 switches::kNtpSwitchToExistingTab, "host"},
497 }; 497 };
498 #endif // OS_ANDROID 498 #endif // OS_ANDROID
499 499
500 #if defined(OS_ANDROID) 500 #if defined(OS_ANDROID)
501 const FeatureEntry::FeatureParam 501 const FeatureEntry::FeatureParam
502 kContentSuggestionsCategoryOrderFeatureVariationGeneral[] = {
503 {ntp_snippets::kCategoryOrderParameter,
504 ntp_snippets::kCategoryOrderGeneral},
505 };
506
507 const FeatureEntry::FeatureParam
508 kContentSuggestionsCategoryOrderFeatureVariationEMOriented[] = {
509 {ntp_snippets::kCategoryOrderParameter,
510 ntp_snippets::kCategoryOrderEmergingMarketsOriented},
511 };
512
513 const FeatureEntry::FeatureVariation
514 kContentSuggestionsCategoryOrderFeatureVariations[] = {
515 {"(general)", kContentSuggestionsCategoryOrderFeatureVariationGeneral,
516 arraysize(kContentSuggestionsCategoryOrderFeatureVariationGeneral),
517 nullptr},
518 {"(emerging markets oriented)",
519 kContentSuggestionsCategoryOrderFeatureVariationEMOriented,
520 arraysize(kContentSuggestionsCategoryOrderFeatureVariationEMOriented),
521 nullptr}};
522
523 const FeatureEntry::FeatureParam
502 kContentSuggestionsCategoryRankerFeatureVariationConstant[] = { 524 kContentSuggestionsCategoryRankerFeatureVariationConstant[] = {
503 {ntp_snippets::kCategoryRankerParameter, 525 {ntp_snippets::kCategoryRankerParameter,
504 ntp_snippets::kCategoryRankerConstantRanker}, 526 ntp_snippets::kCategoryRankerConstantRanker},
505 }; 527 };
506 528
507 const FeatureEntry::FeatureParam 529 const FeatureEntry::FeatureParam
508 kContentSuggestionsCategoryRankerFeatureVariationClickBased[] = { 530 kContentSuggestionsCategoryRankerFeatureVariationClickBased[] = {
509 {ntp_snippets::kCategoryRankerParameter, 531 {ntp_snippets::kCategoryRankerParameter,
510 ntp_snippets::kCategoryRankerClickBasedRanker}, 532 ntp_snippets::kCategoryRankerClickBasedRanker},
511 }; 533 };
(...skipping 1313 matching lines...) Expand 10 before | Expand all | Expand 10 after
1825 {"disable-audio-support-for-desktop-share", 1847 {"disable-audio-support-for-desktop-share",
1826 IDS_FLAG_DISABLE_AUDIO_FOR_DESKTOP_SHARE, 1848 IDS_FLAG_DISABLE_AUDIO_FOR_DESKTOP_SHARE,
1827 IDS_FLAG_DISABLE_AUDIO_FOR_DESKTOP_SHARE_DESCRIPTION, kOsAll, 1849 IDS_FLAG_DISABLE_AUDIO_FOR_DESKTOP_SHARE_DESCRIPTION, kOsAll,
1828 SINGLE_VALUE_TYPE(switches::kDisableAudioSupportForDesktopShare)}, 1850 SINGLE_VALUE_TYPE(switches::kDisableAudioSupportForDesktopShare)},
1829 #if BUILDFLAG(ENABLE_EXTENSIONS) 1851 #if BUILDFLAG(ENABLE_EXTENSIONS)
1830 {"tab-for-desktop-share", IDS_FLAG_DISABLE_TAB_FOR_DESKTOP_SHARE, 1852 {"tab-for-desktop-share", IDS_FLAG_DISABLE_TAB_FOR_DESKTOP_SHARE,
1831 IDS_FLAG_DISABLE_TAB_FOR_DESKTOP_SHARE_DESCRIPTION, kOsAll, 1853 IDS_FLAG_DISABLE_TAB_FOR_DESKTOP_SHARE_DESCRIPTION, kOsAll,
1832 SINGLE_VALUE_TYPE(extensions::switches::kDisableTabForDesktopShare)}, 1854 SINGLE_VALUE_TYPE(extensions::switches::kDisableTabForDesktopShare)},
1833 #endif // ENABLE_EXTENSIONS 1855 #endif // ENABLE_EXTENSIONS
1834 #if defined(OS_ANDROID) 1856 #if defined(OS_ANDROID)
1857 // TODO(vitaliii): Use ntp_snippets::kStudyName as the feature trial.
1858 // Currently, only a single FEATURE_WITH_VARIATIONS_VALUE_TYPE can use a
1859 // given study name. See crbug.com/690450.
1860 {"content-suggestions-category-order",
1861 IDS_FLAGS_CONTENT_SUGGESTIONS_CATEGORY_ORDER_NAME,
1862 IDS_FLAGS_CONTENT_SUGGESTIONS_CATEGORY_ORDER_DESCRIPTION, kOsAndroid,
1863 FEATURE_WITH_VARIATIONS_VALUE_TYPE(
1864 ntp_snippets::kCategoryOrder,
1865 kContentSuggestionsCategoryOrderFeatureVariations,
1866 "content-suggestions-category-order-feature-trial")},
1835 {"content-suggestions-category-ranker", 1867 {"content-suggestions-category-ranker",
1836 IDS_FLAGS_CONTENT_SUGGESTIONS_CATEGORY_RANKER_NAME, 1868 IDS_FLAGS_CONTENT_SUGGESTIONS_CATEGORY_RANKER_NAME,
1837 IDS_FLAGS_CONTENT_SUGGESTIONS_CATEGORY_RANKER_DESCRIPTION, kOsAndroid, 1869 IDS_FLAGS_CONTENT_SUGGESTIONS_CATEGORY_RANKER_DESCRIPTION, kOsAndroid,
1838 FEATURE_WITH_VARIATIONS_VALUE_TYPE( 1870 FEATURE_WITH_VARIATIONS_VALUE_TYPE(
1839 ntp_snippets::kCategoryRanker, 1871 ntp_snippets::kCategoryRanker,
1840 kContentSuggestionsCategoryRankerFeatureVariations, 1872 kContentSuggestionsCategoryRankerFeatureVariations,
1841 ntp_snippets::kStudyName)}, 1873 ntp_snippets::kStudyName)},
1842 {"override-ntp-suggestions-source", IDS_FLAGS_OVERRIDE_SNIPPETS_SOURCE_NAME, 1874 {"override-ntp-suggestions-source", IDS_FLAGS_OVERRIDE_SNIPPETS_SOURCE_NAME,
1843 IDS_FLAGS_OVERRIDE_SNIPPETS_SOURCE_DESCRIPTION, kOsAndroid, 1875 IDS_FLAGS_OVERRIDE_SNIPPETS_SOURCE_DESCRIPTION, kOsAndroid,
1844 FEATURE_WITH_VARIATIONS_VALUE_TYPE(ntp_snippets::kContentSuggestionsSource, 1876 FEATURE_WITH_VARIATIONS_VALUE_TYPE(ntp_snippets::kContentSuggestionsSource,
(...skipping 592 matching lines...) Expand 10 before | Expand all | Expand 10 after
2437 const base::HistogramBase::Sample kBadSwitchFormatHistogramId = 0; 2469 const base::HistogramBase::Sample kBadSwitchFormatHistogramId = 0;
2438 2470
2439 const FeatureEntry* GetFeatureEntries(size_t* count) { 2471 const FeatureEntry* GetFeatureEntries(size_t* count) {
2440 *count = arraysize(kFeatureEntries); 2472 *count = arraysize(kFeatureEntries);
2441 return kFeatureEntries; 2473 return kFeatureEntries;
2442 } 2474 }
2443 2475
2444 } // namespace testing 2476 } // namespace testing
2445 2477
2446 } // namespace about_flags 2478 } // namespace about_flags
OLDNEW
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | components/ntp_snippets/category_rankers/constant_category_ranker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698