mirror of
https://github.com/M66B/FairEmail.git
synced 2026-03-31 06:08:31 +02:00
Added reply button option
This commit is contained in:
@@ -67,6 +67,7 @@ public class FragmentDialogButtons extends FragmentDialogBase {
|
||||
final CheckBox cbHtml = dview.findViewById(R.id.cbHtml);
|
||||
final CheckBox cbRaw = dview.findViewById(R.id.cbRaw);
|
||||
final CheckBox cbUnsubscribe = dview.findViewById(R.id.cbUnsubscribe);
|
||||
final CheckBox cbAnswer = dview.findViewById(R.id.cbAnswer);
|
||||
|
||||
cbTranslate.setVisibility(DeepL.isAvailable(context) ? View.VISIBLE : View.GONE);
|
||||
cbPin.setVisibility(Shortcuts.can(context) ? View.VISIBLE : View.GONE);
|
||||
@@ -96,6 +97,13 @@ public class FragmentDialogButtons extends FragmentDialogBase {
|
||||
cbHtml.setChecked(prefs.getBoolean("button_html", false));
|
||||
cbRaw.setChecked(prefs.getBoolean("button_raw", false));
|
||||
cbUnsubscribe.setChecked(prefs.getBoolean("button_unsubscribe", true));
|
||||
cbAnswer.setChecked(prefs.getBoolean("button_answer", false));
|
||||
|
||||
boolean expand_all = prefs.getBoolean("expand_all", false);
|
||||
boolean expand_one = prefs.getBoolean("expand_one", true);
|
||||
boolean threading = prefs.getBoolean("threading", true);
|
||||
boolean swipe_reply = prefs.getBoolean("swipe_reply", false);
|
||||
cbAnswer.setVisibility((!expand_all && expand_one) || !threading || swipe_reply ? View.VISIBLE : View.GONE);
|
||||
|
||||
return new AlertDialog.Builder(getContext())
|
||||
.setView(dview)
|
||||
@@ -128,6 +136,7 @@ public class FragmentDialogButtons extends FragmentDialogBase {
|
||||
editor.putBoolean("button_html", cbHtml.isChecked());
|
||||
editor.putBoolean("button_raw", cbRaw.isChecked());
|
||||
editor.putBoolean("button_unsubscribe", cbUnsubscribe.isChecked());
|
||||
editor.putBoolean("button_answer", cbAnswer.isChecked());
|
||||
editor.apply();
|
||||
sendResult(Activity.RESULT_OK);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user