Remove getThemedDialog and getAlertDialogStyle

pull/935/head
Alex Baker 4 years ago
parent 46ee03d9bd
commit 25e411528b

@ -67,7 +67,7 @@ public class TimeDurationControlSet implements OnNNumberPickedListener, View.OnC
if (dialog == null) {
dialog =
new NNumberPickerDialog(
theme.getThemedDialog(context),
context,
this,
context.getResources().getString(R.string.DLG_hour_minutes),
new int[] {0, 0},

@ -4,7 +4,6 @@ import static com.todoroo.andlib.utility.AndroidUtilities.atLeastJellybeanMR1;
import android.content.Context;
import android.content.DialogInterface;
import android.view.ContextThemeWrapper;
import android.view.View;
import android.widget.ListAdapter;
import androidx.appcompat.app.AlertDialog;
@ -24,9 +23,7 @@ public class AlertDialogBuilder {
this.context = context;
this.theme = theme;
this.locale = locale;
ContextThemeWrapper wrapper = theme.getThemedDialog(context);
theme.applyToContext(wrapper);
builder = new MaterialAlertDialogBuilder(wrapper);
builder = new MaterialAlertDialogBuilder(context);
}
public AlertDialogBuilder setMessage(int message, Object... formatArgs) {

@ -39,7 +39,7 @@ public class DialogBuilder {
ProgressDialog newProgressDialog() {
ProgressDialog progressDialog =
new ProgressDialog(activity, theme.getThemeBase().getAlertDialogStyle());
new ProgressDialog(activity);
theme.applyToContext(progressDialog.getContext());
if (AndroidUtilities.preLollipop()) {
ColorDrawable background =

@ -42,10 +42,6 @@ public class Theme {
return (LayoutInflater) wrap(context).getSystemService(Context.LAYOUT_INFLATER_SERVICE);
}
public ContextThemeWrapper getThemedDialog(Context context) {
return new ContextThemeWrapper(context, themeBase.getAlertDialogStyle());
}
public void applyThemeAndStatusBarColor(Activity activity) {
applyTheme(activity);
themeColor.applyToSystemBars(activity);

@ -50,10 +50,6 @@ public class ThemeBase implements ColorPickerDialog.Pickable {
dayNightMode = source.readInt();
}
public int getAlertDialogStyle() {
return R.style.TasksDialogAlert;
}
@Override
public String getName() {
return name;

Loading…
Cancel
Save