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

Side by Side Diff: components/previews/core/previews_experiments.h

Issue 2760063002: Add support to previews/ for Server LoFi and LitePages (Closed)
Patch Set: build fix 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
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_PREVIEWS_CORE_PREVIEWS_EXPERIMENTS_H_ 5 #ifndef COMPONENTS_PREVIEWS_CORE_PREVIEWS_EXPERIMENTS_H_
6 #define COMPONENTS_PREVIEWS_CORE_PREVIEWS_EXPERIMENTS_H_ 6 #define COMPONENTS_PREVIEWS_CORE_PREVIEWS_EXPERIMENTS_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 57
58 // The blacklist version for offline previews. 58 // The blacklist version for offline previews.
59 int OfflinePreviewsVersion(); 59 int OfflinePreviewsVersion();
60 60
61 } // namespace params 61 } // namespace params
62 62
63 enum class PreviewsType { 63 enum class PreviewsType {
64 NONE = 0, 64 NONE = 0,
65 // The user is shown an offline page as a preview. 65 // The user is shown an offline page as a preview.
66 OFFLINE = 1, 66 OFFLINE = 1,
67 // The user is shown a server lite page.
68 LITE_PAGE = 2,
69 // The user is shown a server LoFi page.
70 SERVER_LOFI = 3,
67 // Insert new enum values here. Keep values sequential to allow looping 71 // Insert new enum values here. Keep values sequential to allow looping
68 // from NONE+1 to LAST-1. 72 // from NONE+1 to LAST-1.
69 LAST = 2, 73 LAST = 4,
70 }; 74 };
71 75
72 typedef std::vector<std::pair<PreviewsType, int>> PreviewsTypeList; 76 typedef std::vector<std::pair<PreviewsType, int>> PreviewsTypeList;
73 77
74 // Returns true if any client-side previews experiment is active. 78 // Returns true if any client-side previews experiment is active.
75 bool IsIncludedInClientSidePreviewsExperimentsFieldTrial(); 79 bool IsIncludedInClientSidePreviewsExperimentsFieldTrial();
76 80
77 // Sets the appropriate state for field trial and variations to imitate the 81 // Sets the appropriate state for field trial and variations to imitate the
78 // offline pages field trial. 82 // offline pages field trial.
79 bool EnableOfflinePreviewsForTesting(); 83 bool EnableOfflinePreviewsForTesting();
80 84
81 } // namespace previews 85 } // namespace previews
82 86
83 #endif // COMPONENTS_PREVIEWS_CORE_PREVIEWS_EXPERIMENTS_H_ 87 #endif // COMPONENTS_PREVIEWS_CORE_PREVIEWS_EXPERIMENTS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698