Show relative snoozed time

pull/160/head
M66B 5 years ago
parent e94f07bba3
commit e09bd95cc6

@ -13,8 +13,8 @@ android {
applicationId "eu.faircode.email"
minSdkVersion 21
targetSdkVersion 29
versionCode 639
versionName "1.639"
versionCode 640
versionName "1.640"
archivesBaseName = "FairEmail-v$versionName"
// https://en.wikipedia.org/wiki/List_of_dinosaur_genera

@ -52,6 +52,7 @@ import android.text.SpannableStringBuilder;
import android.text.Spanned;
import android.text.TextUtils;
import android.text.TextWatcher;
import android.text.format.DateUtils;
import android.text.method.ArrowKeyMovementMethod;
import android.text.method.LinkMovementMethod;
import android.text.style.DynamicDrawableSpan;
@ -1545,7 +1546,12 @@ public class AdapterMessage extends RecyclerView.Adapter<AdapterMessage.ViewHold
DateFormat D = new SimpleDateFormat("E");
Snackbar.make(
parentFragment.getView(),
D.format(message.ui_snoozed) + " " + DTF.format(message.ui_snoozed),
D.format(message.ui_snoozed) + " " + DTF.format(message.ui_snoozed) + " - " +
DateUtils.getRelativeTimeSpanString(
message.ui_snoozed,
System.currentTimeMillis(),
DateUtils.MINUTE_IN_MILLIS,
DateUtils.FORMAT_ABBREV_RELATIVE),
Snackbar.LENGTH_LONG).show();
}
}

Loading…
Cancel
Save