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

Side by Side Diff: ios/chrome/browser/ui/history/history_entries_status_item.h

Issue 2590473002: Upstream Chrome on iOS source code [5/11]. (Closed)
Patch Set: Created 4 years 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef IOS_CHROME_BROWSER_UI_HISTORY_HISTORY_ENTRIES_STATUS_ITEM_H_
6 #define IOS_CHROME_BROWSER_UI_HISTORY_HISTORY_ENTRIES_STATUS_ITEM_H_
7
8 #import "ios/chrome/browser/ui/collection_view/cells/collection_view_footer_item .h"
9 #import "ios/chrome/browser/ui/collection_view/cells/collection_view_item.h"
10
11 // Type of displayed history entries. Entries can be synced or local, or there
12 // may be no history entries.
13 typedef NS_ENUM(NSInteger, HistoryEntriesStatus) {
14 NO_ENTRIES,
15 LOCAL_ENTRIES,
16 SYNCED_ENTRIES
17 };
18
19 class GURL;
20 @class HistoryEntriesStatusItem;
21 @class LabelLinkController;
22
23 // Delegate HistoryEntriesStatusItem. Handles link taps on
24 // HistoryEntriesStatusCell.
25 @protocol HistoryEntriesStatusItemDelegate<NSObject>
26 // Called when a link is pressed on a HistoryEntriesStatusCell.
27 - (void)historyEntriesStatusItem:(HistoryEntriesStatusItem*)item
28 didRequestOpenURL:(const GURL&)URL;
29
30 @end
31
32 // Model item for HistoryEntriesStatusCell. Manages links added to the cell.
33 @interface HistoryEntriesStatusItem : CollectionViewItem
34 // Status of currently displayed history entries.
35 @property(nonatomic, assign) HistoryEntriesStatus entriesStatus;
36 // YES if messages should be hidden.
37 @property(nonatomic, assign, getter=isHidden) BOOL hidden;
38 // YES if message for other forms of browsing data should be shown.
39 @property(nonatomic, assign) BOOL showsOtherBrowsingDataNotice;
40 // Delegate for HistoryEntriesStatusItem. Is notified when a link is pressed.
41 @property(nonatomic, assign) id<HistoryEntriesStatusItemDelegate> delegate;
42 @end
43
44 // Cell for displaying status for history entry. Provides information on whether
45 // local or synced entries or displays, and how to access other forms of
46 // browsing history, if applicable.
47 @interface HistoryEntriesStatusCell : CollectionViewFooterCell
48 @end
49
50 @interface HistoryEntriesStatusCell (Testing)
51 // Link controller for entries status message.
52 @property(nonatomic, retain, readonly) LabelLinkController* labelLinkController;
53 @end
54
55 #endif // IOS_CHROME_BROWSER_UI_HISTORY_HISTORY_ENTRIES_STATUS_ITEM_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698