mirror of
https://github.com/M66B/FairEmail.git
synced 2025-12-27 08:01:50 +01:00
Refactoring
This commit is contained in:
@@ -36,6 +36,7 @@ import android.text.Spannable;
|
||||
import android.text.Spanned;
|
||||
import android.text.format.DateUtils;
|
||||
import android.text.format.Time;
|
||||
import android.util.TypedValue;
|
||||
import android.view.Menu;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
@@ -280,6 +281,12 @@ public class Helper {
|
||||
}
|
||||
}
|
||||
|
||||
static boolean isDarkTheme(Context context) {
|
||||
TypedValue tv = new TypedValue();
|
||||
context.getTheme().resolveAttribute(R.attr.themeName, tv, true);
|
||||
return (tv.string != null && !"light".contentEquals(tv.string));
|
||||
}
|
||||
|
||||
// Formatting
|
||||
|
||||
static String humanReadableByteCount(long bytes, boolean si) {
|
||||
|
||||
Reference in New Issue
Block a user