|
|
|
@ -108,6 +108,7 @@ public class FragmentOptionsBehavior extends FragmentBase implements SharedPrefe
|
|
|
|
|
private SwitchCompat swSwipeReply;
|
|
|
|
|
private SwitchCompat swMoveThreadAll;
|
|
|
|
|
private SwitchCompat swMoveThreadSent;
|
|
|
|
|
private SwitchCompat swSwipeTrashAll;
|
|
|
|
|
private Button btnDefaultFolder;
|
|
|
|
|
private TextView tvDefaultFolder;
|
|
|
|
|
|
|
|
|
@ -129,7 +130,7 @@ public class FragmentOptionsBehavior extends FragmentBase implements SharedPrefe
|
|
|
|
|
"undo_timeout",
|
|
|
|
|
"autoread", "flag_snoozed", "autounflag", "auto_important", "reset_importance",
|
|
|
|
|
"reset_snooze", "auto_block_sender", "auto_hide_answer", "swipe_reply",
|
|
|
|
|
"move_thread_all", "move_thread_sent",
|
|
|
|
|
"move_thread_all", "move_thread_sent", "swipe_trash_all",
|
|
|
|
|
"default_folder"
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
@ -194,6 +195,7 @@ public class FragmentOptionsBehavior extends FragmentBase implements SharedPrefe
|
|
|
|
|
swSwipeReply = view.findViewById(R.id.swSwipeReply);
|
|
|
|
|
swMoveThreadAll = view.findViewById(R.id.swMoveThreadAll);
|
|
|
|
|
swMoveThreadSent = view.findViewById(R.id.swMoveThreadSent);
|
|
|
|
|
swSwipeTrashAll = view.findViewById(R.id.swSwipeTrashAll);
|
|
|
|
|
btnDefaultFolder = view.findViewById(R.id.btnDefaultFolder);
|
|
|
|
|
tvDefaultFolder = view.findViewById(R.id.tvDefaultFolder);
|
|
|
|
|
|
|
|
|
@ -613,6 +615,13 @@ public class FragmentOptionsBehavior extends FragmentBase implements SharedPrefe
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
swSwipeTrashAll.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
|
|
|
|
|
@Override
|
|
|
|
|
public void onCheckedChanged(CompoundButton compoundButton, boolean checked) {
|
|
|
|
|
prefs.edit().putBoolean("swipe_trash_all", checked).apply();
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
Intent tree = new Intent(Intent.ACTION_OPEN_DOCUMENT_TREE);
|
|
|
|
|
Helper.openAdvanced(getContext(), tree);
|
|
|
|
|
PackageManager pm = getContext().getPackageManager();
|
|
|
|
@ -787,6 +796,7 @@ public class FragmentOptionsBehavior extends FragmentBase implements SharedPrefe
|
|
|
|
|
swMoveThreadAll.setChecked(prefs.getBoolean("move_thread_all", false));
|
|
|
|
|
swMoveThreadSent.setChecked(prefs.getBoolean("move_thread_sent", false));
|
|
|
|
|
swMoveThreadSent.setEnabled(!swMoveThreadAll.isChecked());
|
|
|
|
|
swSwipeTrashAll.setChecked(prefs.getBoolean("swipe_trash_all", true));
|
|
|
|
|
|
|
|
|
|
tvDefaultFolder.setText(prefs.getString("default_folder", null));
|
|
|
|
|
} catch (Throwable ex) {
|
|
|
|
|