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

Side by Side Diff: components/offline_pages/offline_page_feature.cc

Issue 2317723003: [Offline Pages] Removes the deprecated IsOfflinePages synthetic flag since no uses of it remain. (Closed)
Patch Set: Created 4 years, 3 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 | « components/offline_pages/offline_page_feature.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "components/offline_pages/offline_page_feature.h" 5 #include "components/offline_pages/offline_page_feature.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/feature_list.h" 9 #include "base/feature_list.h"
10 10
(...skipping 14 matching lines...) Expand all
25 const base::Feature kOfflinePagesCTFeature { 25 const base::Feature kOfflinePagesCTFeature {
26 "OfflinePagesCT", base::FEATURE_ENABLED_BY_DEFAULT 26 "OfflinePagesCT", base::FEATURE_ENABLED_BY_DEFAULT
27 }; 27 };
28 28
29 const base::Feature kOfflinePagesSharingFeature{ 29 const base::Feature kOfflinePagesSharingFeature{
30 "OfflinePagesSharing", base::FEATURE_DISABLED_BY_DEFAULT}; 30 "OfflinePagesSharing", base::FEATURE_DISABLED_BY_DEFAULT};
31 31
32 const base::Feature kBackgroundLoaderForDownloadsFeature{ 32 const base::Feature kBackgroundLoaderForDownloadsFeature{
33 "BackgroundLoadingForDownloads", base::FEATURE_ENABLED_BY_DEFAULT}; 33 "BackgroundLoadingForDownloads", base::FEATURE_ENABLED_BY_DEFAULT};
34 34
35 bool IsOfflinePagesEnabled() {
36 return IsOfflineBookmarksEnabled() || IsOffliningRecentPagesEnabled() ||
37 IsOfflinePagesBackgroundLoadingEnabled() ||
38 IsOfflinePagesCTEnabled() || IsOfflinePagesSharingEnabled();
39 }
40
41 bool IsOfflineBookmarksEnabled() { 35 bool IsOfflineBookmarksEnabled() {
42 return base::FeatureList::IsEnabled(kOfflineBookmarksFeature); 36 return base::FeatureList::IsEnabled(kOfflineBookmarksFeature);
43 } 37 }
44 38
45 bool IsOffliningRecentPagesEnabled() { 39 bool IsOffliningRecentPagesEnabled() {
46 return base::FeatureList::IsEnabled(kOffliningRecentPagesFeature); 40 return base::FeatureList::IsEnabled(kOffliningRecentPagesFeature);
47 } 41 }
48 42
49 bool IsOfflinePagesBackgroundLoadingEnabled() { 43 bool IsOfflinePagesBackgroundLoadingEnabled() {
50 return base::FeatureList::IsEnabled(kOfflinePagesBackgroundLoadingFeature); 44 return base::FeatureList::IsEnabled(kOfflinePagesBackgroundLoadingFeature);
51 } 45 }
52 46
53 bool IsOfflinePagesCTEnabled() { 47 bool IsOfflinePagesCTEnabled() {
54 return base::FeatureList::IsEnabled(kOfflinePagesCTFeature); 48 return base::FeatureList::IsEnabled(kOfflinePagesCTFeature);
55 } 49 }
56 50
57 bool IsOfflinePagesSharingEnabled() { 51 bool IsOfflinePagesSharingEnabled() {
58 return base::FeatureList::IsEnabled(kOfflinePagesSharingFeature); 52 return base::FeatureList::IsEnabled(kOfflinePagesSharingFeature);
59 } 53 }
60 54
61 bool IsBackgroundLoaderForDownloadsEnabled() { 55 bool IsBackgroundLoaderForDownloadsEnabled() {
62 return base::FeatureList::IsEnabled(kBackgroundLoaderForDownloadsFeature); 56 return base::FeatureList::IsEnabled(kBackgroundLoaderForDownloadsFeature);
63 } 57 }
64 58
65 } // namespace offline_pages 59 } // namespace offline_pages
OLDNEW
« no previous file with comments | « components/offline_pages/offline_page_feature.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698