From 1a62b9a161865bc47bb61c15f5af3e955b1d1144 Mon Sep 17 00:00:00 2001 From: Ritvik Saraf <13ritvik@gmail.com> Date: Sat, 8 Dec 2018 20:32:28 +0530 Subject: [PATCH] removed dislike button, added comment published time --- .../holder/CommentsMiniInfoItemHolder.java | 3 ++ .../main/res/layout/list_comments_item.xml | 31 ++++++------ .../res/layout/list_comments_mini_item.xml | 47 +++++++------------ 3 files changed, 36 insertions(+), 45 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/info_list/holder/CommentsMiniInfoItemHolder.java b/app/src/main/java/org/schabi/newpipe/info_list/holder/CommentsMiniInfoItemHolder.java index 966564221..c2bc86691 100644 --- a/app/src/main/java/org/schabi/newpipe/info_list/holder/CommentsMiniInfoItemHolder.java +++ b/app/src/main/java/org/schabi/newpipe/info_list/holder/CommentsMiniInfoItemHolder.java @@ -21,6 +21,7 @@ public class CommentsMiniInfoItemHolder extends InfoItemHolder { private final TextView itemContentView; private final TextView itemLikesCountView; private final TextView itemDislikesCountView; + private final TextView itemPublishedTime; private static final int commentDefaultLines = 2; private static final int commentExpandedLines = 1000; @@ -31,6 +32,7 @@ public class CommentsMiniInfoItemHolder extends InfoItemHolder { itemThumbnailView = itemView.findViewById(R.id.itemThumbnailView); itemLikesCountView = itemView.findViewById(R.id.detail_thumbs_up_count_view); itemDislikesCountView = itemView.findViewById(R.id.detail_thumbs_down_count_view); + itemPublishedTime = itemView.findViewById(R.id.itemPublishedTime); itemContentView = itemView.findViewById(R.id.itemCommentContentView); } @@ -74,6 +76,7 @@ public class CommentsMiniInfoItemHolder extends InfoItemHolder { if (null != item.getLikeCount()) { itemLikesCountView.setText(String.valueOf(item.getLikeCount())); } + itemPublishedTime.setText(item.getPublishedTime()); itemView.setOnClickListener(view -> { toggleEllipsize(item.getCommentText()); diff --git a/app/src/main/res/layout/list_comments_item.xml b/app/src/main/res/layout/list_comments_item.xml index 16b6107c5..a9b091329 100644 --- a/app/src/main/res/layout/list_comments_item.xml +++ b/app/src/main/res/layout/list_comments_item.xml @@ -49,17 +49,6 @@ android:textSize="@dimen/video_item_search_uploader_text_size" tools:text="Comment Content, Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc tristique vitae sem vitae blanditLorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc tristique vitae sem vitae blanditLorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc tristique vitae sem vitae blandit" /> - - + + + + diff --git a/app/src/main/res/layout/list_comments_mini_item.xml b/app/src/main/res/layout/list_comments_mini_item.xml index 7e8ce1a87..36f3e2e6e 100644 --- a/app/src/main/res/layout/list_comments_mini_item.xml +++ b/app/src/main/res/layout/list_comments_mini_item.xml @@ -20,27 +20,11 @@ android:src="@drawable/buddy_channel_item" tools:ignore="RtlHardcoded"/> - - - - - + + + +