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

Side by Side Diff: components/ntp_snippets/features.h

Issue 2705373004: [Remote suggestions] Add a remote suggestions flag to choose the source (Closed)
Patch Set: Add the other flag Created 3 years, 9 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 | « chrome/browser/about_flags.cc ('k') | components/ntp_snippets/features.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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef COMPONENTS_NTP_SNIPPETS_FEATURES_H_ 5 #ifndef COMPONENTS_NTP_SNIPPETS_FEATURES_H_
6 #define COMPONENTS_NTP_SNIPPETS_FEATURES_H_ 6 #define COMPONENTS_NTP_SNIPPETS_FEATURES_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 10
11 #include "base/feature_list.h" 11 #include "base/feature_list.h"
12 #include "components/ntp_snippets/category_rankers/category_ranker.h" 12 #include "components/ntp_snippets/category_rankers/category_ranker.h"
13 #include "components/prefs/pref_service.h" 13 #include "components/prefs/pref_service.h"
14 14
15 namespace base { 15 namespace base {
16 class Clock; 16 class Clock;
17 } 17 }
18 18
19 namespace ntp_snippets { 19 namespace ntp_snippets {
20 20
21 // Features to turn individual providers/categories on/off. 21 // Features to turn individual providers/categories on/off.
22 // TODO(jkrcal): Rename to kRemoteSuggestionsFeature.
22 extern const base::Feature kArticleSuggestionsFeature; 23 extern const base::Feature kArticleSuggestionsFeature;
23 extern const base::Feature kBookmarkSuggestionsFeature; 24 extern const base::Feature kBookmarkSuggestionsFeature;
24 extern const base::Feature kRecentOfflineTabSuggestionsFeature; 25 extern const base::Feature kRecentOfflineTabSuggestionsFeature;
25 extern const base::Feature kPhysicalWebPageSuggestionsFeature; 26 extern const base::Feature kPhysicalWebPageSuggestionsFeature;
26 extern const base::Feature kForeignSessionsSuggestionsFeature;; 27 extern const base::Feature kForeignSessionsSuggestionsFeature;;
27 28
28 // Feature to allow the 'save to offline' option to appear in the snippets 29 // Feature to allow the 'save to offline' option to appear in the snippets
29 // context menu. 30 // context menu.
30 extern const base::Feature kSaveToOfflineFeature; 31 extern const base::Feature kSaveToOfflineFeature;
31 32
32 // Feature to allow offline badges to appear on snippets. 33 // Feature to allow offline badges to appear on snippets.
33 extern const base::Feature kOfflineBadgeFeature; 34 extern const base::Feature kOfflineBadgeFeature;
34 35
35 // Feature to allow specification of content suggestions source.
36 // TODO(peconn): Figure out how to remove this, it is useful to specify the
37 // source, but you shouldn't be able to disable it.
38 extern const base::Feature kContentSuggestionsSource;
39
40 // Feature to allow UI as specified here: https://crbug.com/660837. 36 // Feature to allow UI as specified here: https://crbug.com/660837.
41 extern const base::Feature kIncreasedVisibility; 37 extern const base::Feature kIncreasedVisibility;
42 38
43 // Feature to prefer AMP URLs over regular URLs when available. 39 // Feature to prefer AMP URLs over regular URLs when available.
44 extern const base::Feature kPreferAmpUrlsFeature; 40 extern const base::Feature kPreferAmpUrlsFeature;
45 41
46 // Feature to choose a category ranker. 42 // Feature to choose a category ranker.
47 extern const base::Feature kCategoryRanker; 43 extern const base::Feature kCategoryRanker;
48 44
49 // Parameter and its values for the kCategoryRanker feature flag. 45 // Parameter and its values for the kCategoryRanker feature flag.
(...skipping 26 matching lines...) Expand all
76 GENERAL, 72 GENERAL,
77 EMERGING_MARKETS_ORIENTED, 73 EMERGING_MARKETS_ORIENTED,
78 }; 74 };
79 75
80 // Returns which category order to use according to kCategoryOrder feature. 76 // Returns which category order to use according to kCategoryOrder feature.
81 CategoryOrderChoice GetSelectedCategoryOrder(); 77 CategoryOrderChoice GetSelectedCategoryOrder();
82 78
83 } // namespace ntp_snippets 79 } // namespace ntp_snippets
84 80
85 #endif // COMPONENTS_NTP_SNIPPETS_FEATURES_H_ 81 #endif // COMPONENTS_NTP_SNIPPETS_FEATURES_H_
OLDNEW
« no previous file with comments | « chrome/browser/about_flags.cc ('k') | components/ntp_snippets/features.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698