From 4881e29f195e3cc36795ab2c0ffcad473f740a58 Mon Sep 17 00:00:00 2001 From: Konrad Pozniak Date: Thu, 25 Apr 2019 19:29:15 +0200 Subject: [PATCH] fix StatusDetailedVieHolder ignoring useAbsoluteTime setting (#1215) --- .../tusky/adapter/StatusDetailedViewHolder.java | 8 ++++---- .../com/keylesspalace/tusky/adapter/ThreadAdapter.java | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/com/keylesspalace/tusky/adapter/StatusDetailedViewHolder.java b/app/src/main/java/com/keylesspalace/tusky/adapter/StatusDetailedViewHolder.java index dcfd8bc4..d6403a72 100644 --- a/app/src/main/java/com/keylesspalace/tusky/adapter/StatusDetailedViewHolder.java +++ b/app/src/main/java/com/keylesspalace/tusky/adapter/StatusDetailedViewHolder.java @@ -42,8 +42,8 @@ class StatusDetailedViewHolder extends StatusBaseViewHolder { private TextView cardUrl; private View infoDivider; - StatusDetailedViewHolder(View view) { - super(view, false); + StatusDetailedViewHolder(View view, boolean useAbsoluteTime) { + super(view, useAbsoluteTime); reblogs = view.findViewById(R.id.status_reblogs); favourites = view.findViewById(R.id.status_favourites); cardView = view.findViewById(R.id.card_view); @@ -126,8 +126,8 @@ class StatusDetailedViewHolder extends StatusBaseViewHolder { @Override protected void setupWithStatus(final StatusViewData.Concrete status, final StatusActionListener listener, boolean mediaPreviewEnabled, @Nullable Object payloads) { - super.setupWithStatus(status, listener, mediaPreviewEnabled,payloads); - if (payloads==null) { + super.setupWithStatus(status, listener, mediaPreviewEnabled, payloads); + if (payloads == null) { setReblogAndFavCount(status.getReblogsCount(), status.getFavouritesCount(), listener); setApplication(status.getApplication()); diff --git a/app/src/main/java/com/keylesspalace/tusky/adapter/ThreadAdapter.java b/app/src/main/java/com/keylesspalace/tusky/adapter/ThreadAdapter.java index 3df88642..4f394da0 100644 --- a/app/src/main/java/com/keylesspalace/tusky/adapter/ThreadAdapter.java +++ b/app/src/main/java/com/keylesspalace/tusky/adapter/ThreadAdapter.java @@ -60,7 +60,7 @@ public class ThreadAdapter extends RecyclerView.Adapter { case VIEW_TYPE_STATUS_DETAILED: { View view = LayoutInflater.from(parent.getContext()) .inflate(R.layout.item_status_detailed, parent, false); - return new StatusDetailedViewHolder(view); + return new StatusDetailedViewHolder(view, useAbsoluteTime); } } }