OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_BOOKMARKS_ENHANCED_BOOKMARKS_FEATURES_H_ | 5 #ifndef CHROME_BROWSER_BOOKMARKS_ENHANCED_BOOKMARKS_FEATURES_H_ |
6 #define CHROME_BROWSER_BOOKMARKS_ENHANCED_BOOKMARKS_FEATURES_H_ | 6 #define CHROME_BROWSER_BOOKMARKS_ENHANCED_BOOKMARKS_FEATURES_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "extensions/common/extension.h" | 10 #include "extensions/common/extension.h" |
11 | 11 |
12 class PrefService; | 12 class PrefService; |
13 | 13 |
14 // States for bookmark experiment. They are set by Chrome sync into | 14 // States for bookmark experiment. They are set by Chrome sync into |
15 // sync_driver::prefs::kEnhancedBookmarksExperimentEnabled user preference and | 15 // sync_driver::prefs::kEnhancedBookmarksExperimentEnabled user preference and |
16 // used for UMA reporting as well. | 16 // used for UMA reporting as well. |
17 enum BookmarksExperimentState { | 17 enum BookmarksExperimentState { |
18 kNoBookmarksExperiment, | 18 NO_BOOKMARKS_EXPERIMENT, |
sky
2014/05/30 20:23:52
BOOKMARKS_EXPERIMENT_NONE (style guide for content
yefimt
2014/05/30 20:42:38
Done.
| |
19 kBookmarksExperimentEnabled, | 19 BOOKMARKS_EXPERIMENT_ENABLED, |
20 kBookmarksExperimentEnabledUserOptOut, | 20 BOOKMARKS_EXPERIMENT_ENABLED_USER_OPTOUT, |
sky
2014/05/30 20:23:52
OPT_OUT
yefimt
2014/05/30 20:42:38
Done.
| |
21 kBookmarksExperimentEnabledFromFinch, | 21 BOOKMARKS_EXPERIMENT_ENABLED_FROM_FINCH, |
22 kBookmarksExperimentOptOutFromFinch, | 22 BOOKMARKS_EXPERIMENT_OPTOUT_FROM_FINCH, |
sky
2014/05/30 20:23:52
OPT_OUT
yefimt
2014/05/30 20:42:38
Done.
| |
23 kBookmarksExperimentEnabledFromFinchUserSignedIn, | 23 BOOKMARKS_EXPERIMENT_ENABLED_FROM_FINCH_USER_SIGNEDIN, |
24 kBookmarksExperimentEnabledFromSyncUnknown, | 24 BOOKMARKS_EXPERIMENT_ENABLED_FROM_SYNC_UNKNOWN, |
25 kBookmarksExperimentEnumSize | 25 BOOKMARKS_EXPERIMENT_ENUM_SIZE |
26 }; | 26 }; |
27 | 27 |
28 // Returns true and sets |extension_id| if bookmarks experiment enabled | 28 // Returns true and sets |extension_id| if bookmarks experiment enabled |
29 // false if no bookmark experiment or extension id is empty. | 29 // false if no bookmark experiment or extension id is empty. |
30 bool GetBookmarksExperimentExtensionID(const PrefService* user_prefs, | 30 bool GetBookmarksExperimentExtensionID(const PrefService* user_prefs, |
31 std::string* extension_id); | 31 std::string* extension_id); |
32 | 32 |
33 // Updates bookmark experiment state based on information from Chrome sync | 33 // Updates bookmark experiment state based on information from Chrome sync |
34 // and Finch experiments. | 34 // and Finch experiments. |
35 void UpdateBookmarksExperimentState( | 35 void UpdateBookmarksExperimentState( |
(...skipping 11 matching lines...) Expand all Loading... | |
47 // Experiment could be enable from Chrome sync or from Finch. | 47 // Experiment could be enable from Chrome sync or from Finch. |
48 bool IsEnhancedBookmarksExperimentEnabled(); | 48 bool IsEnhancedBookmarksExperimentEnabled(); |
49 | 49 |
50 // Returns true when flag enable-dom-distiller is set or enabled from Finch. | 50 // Returns true when flag enable-dom-distiller is set or enabled from Finch. |
51 bool IsEnableDomDistillerSet(); | 51 bool IsEnableDomDistillerSet(); |
52 | 52 |
53 // Returns true when flag enable-sync-articles is set or enabled from Finch. | 53 // Returns true when flag enable-sync-articles is set or enabled from Finch. |
54 bool IsEnableSyncArticlesSet(); | 54 bool IsEnableSyncArticlesSet(); |
55 | 55 |
56 #endif // CHROME_BROWSER_BOOKMARKS_ENHANCED_BOOKMARKS_FEATURES_H_ | 56 #endif // CHROME_BROWSER_BOOKMARKS_ENHANCED_BOOKMARKS_FEATURES_H_ |
OLD | NEW |