mirror of
https://codeberg.org/Bazsalanszky/Infinity-For-Lemmy.git
synced 2024-12-25 10:28:22 +01:00
Fixes community names on CompactLayout and User posts page
Replaced the reddit specific "r/" prefix. Closes #26
This commit is contained in:
parent
5e4793bdaf
commit
e9ecae117d
@ -190,7 +190,7 @@ public class CommentsListingRecyclerViewAdapter extends PagedListAdapter<Comment
|
||||
if (holder instanceof CommentViewHolder) {
|
||||
Comment comment = getItem(holder.getBindingAdapterPosition());
|
||||
if (comment != null) {
|
||||
String name = "r/" + comment.getCommunityName();
|
||||
String name = comment.getCommunityQualifiedName();
|
||||
((CommentViewHolder) holder).authorTextView.setText(name);
|
||||
((CommentViewHolder) holder).authorTextView.setTextColor(mSubredditColor);
|
||||
|
||||
|
@ -1155,7 +1155,7 @@ public class PostRecyclerViewAdapter extends PagingDataAdapter<Post, RecyclerVie
|
||||
if (mHideSubredditAndUserPrefix) {
|
||||
((PostCompactBaseViewHolder) holder).nameTextView.setText(post.getSubredditName());
|
||||
} else {
|
||||
((PostCompactBaseViewHolder) holder).nameTextView.setText("r/" + post.getSubredditName());
|
||||
((PostCompactBaseViewHolder) holder).nameTextView.setText(post.getSubredditNamePrefixed());
|
||||
}
|
||||
} else {
|
||||
if (post.getAuthorIconUrl() == null) {
|
||||
|
@ -298,7 +298,7 @@ public class ParseComment {
|
||||
String commentRawText = commentObj.getString("content");
|
||||
String linkId = postObj.getString("id");
|
||||
String communityName = communityObj.getString("name");
|
||||
String communityQualifiedName = communityObj.getString("actor_id");
|
||||
String communityQualifiedName = LemmyUtils.actorID2FullName(communityObj.getString("actor_id"));
|
||||
|
||||
int score = countsObj.getInt("score");
|
||||
int voteType = (jsonObject.isNull("my_vote")) ? 0 : jsonObject.getInt("my_vote");
|
||||
|
Loading…
Reference in New Issue
Block a user