| Index: chrome/browser/bookmarks/enhanced_bookmarks_features.h
|
| diff --git a/chrome/browser/bookmarks/enhanced_bookmarks_features.h b/chrome/browser/bookmarks/enhanced_bookmarks_features.h
|
| index c3bf9591dc17834bc481ccc26d2ad621cd0a0dee..f67c96a11dfad6e7fdb9789607741b76ef82cf22 100644
|
| --- a/chrome/browser/bookmarks/enhanced_bookmarks_features.h
|
| +++ b/chrome/browser/bookmarks/enhanced_bookmarks_features.h
|
| @@ -11,18 +11,37 @@
|
|
|
| class PrefService;
|
|
|
| +// States for bookmark experiment. They are set by Chrome sync into
|
| +// sync_driver::prefs::kEnhancedBookmarksExperimentEnabled user preference and
|
| +// used for UMA reporting as well.
|
| enum BookmarksExperimentState {
|
| kNoBookmarksExperiment,
|
| kBookmarksExperimentEnabled,
|
| - kBookmarksExperimentEnabledUserOptOut
|
| + kBookmarksExperimentEnabledUserOptOut,
|
| + kBookmarksExperimentEnabledFromFinch,
|
| + kBookmarksExperimentOptOutFromFinch,
|
| + kBookmarksExperimentEnabledFromFinchUserSignedIn,
|
| + kBookmarksExperimentEnumSize
|
| };
|
|
|
| +// Returns true and sets |extension_id| if bookmarks experiment enabled
|
| +// false if no bookmark experiment or extension id is empty.
|
| +bool GetBookmarksExperimentExtensionID(const PrefService* user_prefs,
|
| + std::string* extension_id);
|
| +
|
| +// Updates bookmark experiment state based on information from Chrome sync
|
| +// and Finch experiments.
|
| +void UpdateBookmarksExperimentState(const PrefService* user_prefs,
|
| + PrefService* local_state,
|
| + bool user_signed_in);
|
| +
|
| // Sets flag to opt-in user into Finch experiment.
|
| -void UpdateBookmarksExperiment(
|
| +void ForceFinchBookmarkExperimentIfNeeded(
|
| PrefService* local_state,
|
| BookmarksExperimentState bookmarks_experiment_state);
|
|
|
| // Returns true if enhanced bookmarks experiment is enabled.
|
| +// Experiment could be enable from Chrome sync or from Finch.
|
| bool IsEnhancedBookmarksExperimentEnabled();
|
|
|
| // Returns true when flag enable-dom-distiller is set or enabled from Finch.
|
| @@ -31,7 +50,4 @@ bool IsEnableDomDistillerSet();
|
| // Returns true when flag enable-sync-articles is set or enabled from Finch.
|
| bool IsEnableSyncArticlesSet();
|
|
|
| -// Get extension id from Finch EnhancedBookmarks group parameters.
|
| -std::string GetEnhancedBookmarksExtensionIdFromFinch();
|
| -
|
| #endif // CHROME_BROWSER_BOOKMARKS_ENHANCED_BOOKMARKS_FEATURES_H_
|
|
|