|
|
|
@ -111,7 +111,7 @@ public class FragmentOptionsDisplay extends FragmentBase implements SharedPrefer
|
|
|
|
|
|
|
|
|
|
private SwitchCompat swHighlightUnread;
|
|
|
|
|
private ViewButtonColor btnHighlightColor;
|
|
|
|
|
private SwitchCompat swColorStripe;
|
|
|
|
|
private Spinner spAccountColor;
|
|
|
|
|
private SwitchCompat swColorStripeWide;
|
|
|
|
|
private SwitchCompat swAvatars;
|
|
|
|
|
private ImageButton ibBimi;
|
|
|
|
@ -220,7 +220,7 @@ public class FragmentOptionsDisplay extends FragmentBase implements SharedPrefer
|
|
|
|
|
"portrait2", "portrait2c", "landscape", "close_pane", "column_width",
|
|
|
|
|
"hide_toolbar", "edge_to_edge", "nav_options", "nav_categories", "nav_last_sync", "nav_count", "nav_unseen_drafts", "nav_count_pinned", "show_unexposed",
|
|
|
|
|
"threading", "threading_unread", "indentation", "seekbar", "actionbar", "actionbar_swap", "actionbar_color",
|
|
|
|
|
"highlight_unread", "highlight_color", "color_stripe", "color_stripe_wide",
|
|
|
|
|
"highlight_unread", "highlight_color", "account_color", "color_stripe_wide",
|
|
|
|
|
"avatars", "bimi", "bimi_vmc", "gravatars", "libravatars", "favicons", "favicons_partial", "favicons_manifest", "ddg_icons", "favicons_dmarc", "generated_icons", "identicons",
|
|
|
|
|
"circular", "saturation", "brightness", "threshold",
|
|
|
|
|
"email_format", "prefer_contact", "only_contact", "distinguish_contacts", "show_recipients", "reverse_addresses",
|
|
|
|
@ -294,7 +294,7 @@ public class FragmentOptionsDisplay extends FragmentBase implements SharedPrefer
|
|
|
|
|
|
|
|
|
|
swHighlightUnread = view.findViewById(R.id.swHighlightUnread);
|
|
|
|
|
btnHighlightColor = view.findViewById(R.id.btnHighlightColor);
|
|
|
|
|
swColorStripe = view.findViewById(R.id.swColorStripe);
|
|
|
|
|
spAccountColor = view.findViewById(R.id.spAccountColor);
|
|
|
|
|
swColorStripeWide = view.findViewById(R.id.swColorStripeWide);
|
|
|
|
|
swAvatars = view.findViewById(R.id.swAvatars);
|
|
|
|
|
swBimi = view.findViewById(R.id.swBimi);
|
|
|
|
@ -801,11 +801,17 @@ public class FragmentOptionsDisplay extends FragmentBase implements SharedPrefer
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
swColorStripe.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
|
|
|
|
|
spAccountColor.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
|
|
|
|
|
@Override
|
|
|
|
|
public void onCheckedChanged(CompoundButton compoundButton, boolean checked) {
|
|
|
|
|
prefs.edit().putBoolean("color_stripe", checked).apply();
|
|
|
|
|
//swColorStripeWide.setEnabled(checked);
|
|
|
|
|
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
|
|
|
|
|
prefs.edit().putInt("account_color", position).apply();
|
|
|
|
|
swColorStripeWide.setEnabled(position == 1);
|
|
|
|
|
WidgetUnified.updateData(getContext());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public void onNothingSelected(AdapterView<?> parent) {
|
|
|
|
|
prefs.edit().remove("account_color").apply();
|
|
|
|
|
WidgetUnified.updateData(getContext());
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
@ -1640,9 +1646,9 @@ public class FragmentOptionsDisplay extends FragmentBase implements SharedPrefer
|
|
|
|
|
btnHighlightColor.setColor(prefs.getInt("highlight_color",
|
|
|
|
|
Helper.resolveColor(getContext(), R.attr.colorUnreadHighlight)));
|
|
|
|
|
|
|
|
|
|
swColorStripe.setChecked(prefs.getBoolean("color_stripe", true));
|
|
|
|
|
spAccountColor.setSelection(prefs.getInt("account_color", 1));
|
|
|
|
|
swColorStripeWide.setChecked(prefs.getBoolean("color_stripe_wide", false));
|
|
|
|
|
//swColorStripeWide.setEnabled(swColorStripe.isChecked());
|
|
|
|
|
swColorStripeWide.setEnabled(spAccountColor.getSelectedItemPosition() == 1);
|
|
|
|
|
swAvatars.setChecked(prefs.getBoolean("avatars", true));
|
|
|
|
|
swBimi.setChecked(prefs.getBoolean("bimi", false));
|
|
|
|
|
swBimiVmc.setChecked(prefs.getBoolean("bimi_vmc", false));
|
|
|
|
|