mirror of
https://github.com/M66B/FairEmail.git
synced 2026-01-02 11:01:23 +01:00
Highlight unread messages
This commit is contained in:
@@ -20,11 +20,10 @@ package eu.faircode.email;
|
||||
*/
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.Resources;
|
||||
import android.content.res.TypedArray;
|
||||
import android.os.Build;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import android.util.TypedValue;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.IOException;
|
||||
@@ -34,10 +33,11 @@ public class Helper {
|
||||
static final String TAG = BuildConfig.APPLICATION_ID;
|
||||
|
||||
static int resolveColor(Context context, int attr) {
|
||||
TypedValue typedValue = new TypedValue();
|
||||
Resources.Theme theme = context.getTheme();
|
||||
theme.resolveAttribute(attr, typedValue, true);
|
||||
return typedValue.data;
|
||||
int[] attrs = new int[]{attr};
|
||||
TypedArray a = context.getTheme().obtainStyledAttributes(attrs);
|
||||
int color = a.getColor(0, 0xFF0000);
|
||||
a.recycle();
|
||||
return color;
|
||||
}
|
||||
|
||||
static String localizeFolderName(Context context, String name) {
|
||||
|
||||
Reference in New Issue
Block a user