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

Unified Diff: ios/chrome/browser/ui/suggestions/suggestions_collection_updater.mm

Issue 2618333005: Suggestions UI - Add Article items (Closed)
Patch Set: Remove data source Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ios/chrome/browser/ui/suggestions/suggestions_article_item_unittest.mm ('k') | ios/chrome/test/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/browser/ui/suggestions/suggestions_collection_updater.mm
diff --git a/ios/chrome/browser/ui/suggestions/suggestions_collection_updater.mm b/ios/chrome/browser/ui/suggestions/suggestions_collection_updater.mm
index 495321a1bc89cb9d456e754bb914179fdace1e8c..51814e358875aebf85abd3039197e6f38918baaf 100644
--- a/ios/chrome/browser/ui/suggestions/suggestions_collection_updater.mm
+++ b/ios/chrome/browser/ui/suggestions/suggestions_collection_updater.mm
@@ -6,6 +6,7 @@
#import "ios/chrome/browser/ui/collection_view/collection_view_controller.h"
#import "ios/chrome/browser/ui/collection_view/collection_view_model.h"
+#import "ios/chrome/browser/ui/suggestions/suggestions_article_item.h"
#import "ios/chrome/browser/ui/suggestions/suggestions_item.h"
#if !defined(__has_feature) || !__has_feature(objc_arc)
@@ -39,6 +40,14 @@ typedef NS_ENUM(NSInteger, ItemType) {
title:@"The title"
subtitle:@"The subtitle"]
toSectionWithIdentifier:sectionIdentifier];
+ [model addItem:
+ [[SuggestionsArticleItem alloc]
+ initWithType:ItemTypeArticle
+ title:@"Title of an Article"
+ subtitle:@"This is the subtitle of an article, can "
+ @"spawn on multiple lines"
+ image:[UIImage imageNamed:@"distillation_success"]]
+ toSectionWithIdentifier:sectionIdentifier];
sectionIdentifier++;
}
}
« no previous file with comments | « ios/chrome/browser/ui/suggestions/suggestions_article_item_unittest.mm ('k') | ios/chrome/test/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698