| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 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 | 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 IOS_CHROME_BROWSER_UI_CONTENT_SUGGESTIONS_CONTENT_SUGGESTIONS_ARTICLE_IT
EM_H_ | 5 #ifndef IOS_CHROME_BROWSER_UI_CONTENT_SUGGESTIONS_CONTENT_SUGGESTIONS_ARTICLE_IT
EM_H_ |
| 6 #define IOS_CHROME_BROWSER_UI_CONTENT_SUGGESTIONS_CONTENT_SUGGESTIONS_ARTICLE_IT
EM_H_ | 6 #define IOS_CHROME_BROWSER_UI_CONTENT_SUGGESTIONS_CONTENT_SUGGESTIONS_ARTICLE_IT
EM_H_ |
| 7 | 7 |
| 8 #import "ios/chrome/browser/ui/collection_view/cells/collection_view_item.h" | 8 #import "ios/chrome/browser/ui/collection_view/cells/collection_view_item.h" |
| 9 #import "ios/chrome/browser/ui/content_suggestions/content_suggestion_identifier
.h" | 9 #import "ios/chrome/browser/ui/content_suggestions/content_suggestion_identifier
.h" |
| 10 #import "ios/third_party/material_components_ios/src/components/CollectionCells/
src/MaterialCollectionCells.h" | 10 #import "ios/third_party/material_components_ios/src/components/CollectionCells/
src/MaterialCollectionCells.h" |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 delegate:(id<ContentSuggestionsArticleItemDelegate>)delegate | 36 delegate:(id<ContentSuggestionsArticleItemDelegate>)delegate |
| 37 url:(const GURL&)url NS_DESIGNATED_INITIALIZER; | 37 url:(const GURL&)url NS_DESIGNATED_INITIALIZER; |
| 38 | 38 |
| 39 - (instancetype)initWithType:(NSInteger)type NS_UNAVAILABLE; | 39 - (instancetype)initWithType:(NSInteger)type NS_UNAVAILABLE; |
| 40 | 40 |
| 41 @property(nonatomic, copy, readonly) NSString* title; | 41 @property(nonatomic, copy, readonly) NSString* title; |
| 42 @property(nonatomic, strong) UIImage* image; | 42 @property(nonatomic, strong) UIImage* image; |
| 43 @property(nonatomic, readonly, assign) GURL articleURL; | 43 @property(nonatomic, readonly, assign) GURL articleURL; |
| 44 @property(nonatomic, copy) NSString* publisher; | 44 @property(nonatomic, copy) NSString* publisher; |
| 45 @property(nonatomic, assign) base::Time publishDate; | 45 @property(nonatomic, assign) base::Time publishDate; |
| 46 | 46 @property(nonatomic, weak) id<ContentSuggestionsArticleItemDelegate> delegate; |
| 47 // Whether the image is being fetched. This property is set by the delegate. | |
| 48 @property(nonatomic, assign) BOOL imageBeingFetched; | |
| 49 | 47 |
| 50 @end | 48 @end |
| 51 | 49 |
| 52 // Corresponding cell for an article in the suggestions. | 50 // Corresponding cell for an article in the suggestions. |
| 53 @interface ContentSuggestionsArticleCell : MDCCollectionViewCell | 51 @interface ContentSuggestionsArticleCell : MDCCollectionViewCell |
| 54 | 52 |
| 55 @property(nonatomic, readonly, strong) UILabel* titleLabel; | 53 @property(nonatomic, readonly, strong) UILabel* titleLabel; |
| 56 @property(nonatomic, readonly, strong) UILabel* subtitleLabel; | 54 @property(nonatomic, readonly, strong) UILabel* subtitleLabel; |
| 57 @property(nonatomic, readonly, strong) UIImageView* imageView; | 55 @property(nonatomic, readonly, strong) UIImageView* imageView; |
| 58 | 56 |
| 59 - (void)setPublisherName:(NSString*)publisherName date:(base::Time)publishDate; | 57 - (void)setPublisherName:(NSString*)publisherName date:(base::Time)publishDate; |
| 60 | 58 |
| 61 @end | 59 @end |
| 62 | 60 |
| 63 #endif // IOS_CHROME_BROWSER_UI_CONTENT_SUGGESTIONS_CONTENT_SUGGESTIONS_ARTICLE
_ITEM_H_ | 61 #endif // IOS_CHROME_BROWSER_UI_CONTENT_SUGGESTIONS_CONTENT_SUGGESTIONS_ARTICLE
_ITEM_H_ |
| OLD | NEW |