From 44a553efac0c39407059f8795a3133040259da99 Mon Sep 17 00:00:00 2001 From: Thomas Date: Mon, 24 Apr 2023 16:14:27 +0200 Subject: Show if comments are edited (#1388) --- .../adapters/CommentsRecyclerViewAdapter.java | 12 ++++++++++++ .../docilealligator/infinityforreddit/comment/Comment.java | 11 ++++++++++- .../infinityforreddit/comment/ParseComment.java | 5 ++++- .../docilealligator/infinityforreddit/utils/JSONUtils.java | 1 + app/src/main/res/layout/item_comment.xml | 12 ++++++++++++ app/src/main/res/values/strings.xml | 3 +++ 6 files changed, 42 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/CommentsRecyclerViewAdapter.java b/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/CommentsRecyclerViewAdapter.java index de67008f..fa34151b 100644 --- a/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/CommentsRecyclerViewAdapter.java +++ b/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/CommentsRecyclerViewAdapter.java @@ -459,6 +459,16 @@ public class CommentsRecyclerViewAdapter extends RecyclerView.Adapter { + Toast.makeText(view.getContext(), view.getContext().getString(R.string.edited_time, mShowElapsedTime ? + Utils.getElapsedTime(mActivity, comment.getEditedTimeMillis()) : + Utils.getFormattedTime(mLocale, comment.getEditedTimeMillis(), mTimeFormatPattern) + ), Toast.LENGTH_SHORT).show(); + }); + } ((CommentViewHolder) holder).commentIndentationView.setShowOnlyOneDivider(mShowOnlyOneCommentLevelIndicator); ((CommentViewHolder) holder).commentIndentationView.setLevelAndColors(comment.getDepth(), verticalBlockColors); @@ -1181,6 +1191,8 @@ public class CommentsRecyclerViewAdapter extends RecyclerView.Adapter + + Award given Failed + Edited + Edited on %s + Warning This is a NSFW subreddit. This user has NSFW content -- cgit v1.2.3