mirror of
https://github.com/M66B/FairEmail.git
synced 2026-01-04 03:43:55 +01:00
SimpleTask: reuse themed context
This commit is contained in:
@@ -61,6 +61,7 @@ public abstract class SimpleTask<T> implements LifecycleObserver {
|
||||
|
||||
private static PowerManager.WakeLock wl = null;
|
||||
private static ExecutorService globalExecutor = null;
|
||||
private static Context themedContext = null;
|
||||
private static final List<SimpleTask> tasks = new ArrayList<>();
|
||||
|
||||
private static final int MAX_WAKELOCK = 30 * 60 * 1000; // milliseconds
|
||||
@@ -155,7 +156,8 @@ public abstract class SimpleTask<T> implements LifecycleObserver {
|
||||
}
|
||||
};
|
||||
|
||||
Context themedContext = new ContextThemeWrapper(
|
||||
if (themedContext == null)
|
||||
themedContext = new ContextThemeWrapper(
|
||||
context.getApplicationContext(),
|
||||
FragmentDialogTheme.getTheme(context));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user