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

Side by Side Diff: ios/chrome/browser/ui/reading_list/reading_list_utils.mm

Issue 2784803002: Add mediation for ReadingList distillation state (Closed)
Patch Set: Fix build Created 3 years, 8 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 | « ios/chrome/browser/ui/reading_list/reading_list_utils.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
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #import "ios/chrome/browser/ui/reading_list/reading_list_utils.h"
6
7 #if !defined(__has_feature) || !__has_feature(objc_arc)
8 #error "This file requires ARC support."
9 #endif
10
11 ReadingListUIDistillationStatus UIStatusFromModelStatus(
12 ReadingListEntry::DistillationState distillation_state) {
13 switch (distillation_state) {
lpromero 2017/03/30 12:58:27 Nice. So it was not even 1:1 in our use case.
14 case ReadingListEntry::WILL_RETRY:
15 case ReadingListEntry::PROCESSING:
16 case ReadingListEntry::WAITING:
17 return ReadingListUIDistillationStatusPending;
18 case ReadingListEntry::PROCESSED:
19 return ReadingListUIDistillationStatusSuccess;
20 case ReadingListEntry::DISTILLATION_ERROR:
21 return ReadingListUIDistillationStatusFailure;
22 }
23 }
OLDNEW
« no previous file with comments | « ios/chrome/browser/ui/reading_list/reading_list_utils.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698