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

Unified Diff: ios/chrome/browser/ui/reading_list/reading_list_collection_view_controller.mm

Issue 2768933005: Use CollectionViewTextItem instead of a cast (Closed)
Patch Set: Remove MDFRoboto 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 side-by-side diff with in-line comments
Download patch
Index: ios/chrome/browser/ui/reading_list/reading_list_collection_view_controller.mm
diff --git a/ios/chrome/browser/ui/reading_list/reading_list_collection_view_controller.mm b/ios/chrome/browser/ui/reading_list/reading_list_collection_view_controller.mm
index 91d89ff5b93f50ab35219a547dde88c3acc7d28e..1f414a69ba0cd9fe9decb2a81dc967a516642eed 100644
--- a/ios/chrome/browser/ui/reading_list/reading_list_collection_view_controller.mm
+++ b/ios/chrome/browser/ui/reading_list/reading_list_collection_view_controller.mm
@@ -276,20 +276,6 @@ using ItemsMapByDate = std::multimap<int64_t, ReadingListCollectionViewItem*>;
#pragma mark - UICollectionViewDelegate
-- (UICollectionReusableView*)collectionView:(UICollectionView*)collectionView
- viewForSupplementaryElementOfKind:(NSString*)kind
- atIndexPath:(NSIndexPath*)indexPath {
- UICollectionReusableView* cell = [super collectionView:collectionView
- viewForSupplementaryElementOfKind:kind
- atIndexPath:indexPath];
- MDCCollectionViewTextCell* textCell =
- base::mac::ObjCCast<MDCCollectionViewTextCell>(cell);
- if (textCell) {
- textCell.textLabel.textColor = [[MDCPalette greyPalette] tint500];
- }
- return cell;
-};
-
- (void)collectionView:(UICollectionView*)collectionView
didSelectItemAtIndexPath:(NSIndexPath*)indexPath {
[super collectionView:collectionView didSelectItemAtIndexPath:indexPath];
@@ -1143,6 +1129,7 @@ using ItemsMapByDate = std::multimap<int64_t, ReadingListCollectionViewItem*>;
header.text = l10n_util::GetNSString(IDS_IOS_READING_LIST_UNREAD_HEADER);
break;
}
+ header.textColor = [[MDCPalette greyPalette] tint500];
return header;
}

Powered by Google App Engine
This is Rietveld 408576698