Allow excluding trash/spam for account search

pull/199/head
M66B 3 years ago
parent 697bda090b
commit 86c2ee5f66

@ -225,7 +225,7 @@ public class BoundaryCallbackMessages extends PagedList.BoundaryCallback<TupleMe
" matches=" + (state.matches == null ? null : state.matches.size())); " matches=" + (state.matches == null ? null : state.matches.size()));
long[] exclude = new long[0]; long[] exclude = new long[0];
if (account == null) { if (folder == null) {
List<Long> folders = new ArrayList<>(); List<Long> folders = new ArrayList<>();
if (!criteria.in_trash) { if (!criteria.in_trash) {
List<EntityFolder> trash = db.folder().getFoldersByType(EntityFolder.TRASH); List<EntityFolder> trash = db.folder().getFoldersByType(EntityFolder.TRASH);

@ -227,7 +227,7 @@ public class FragmentDialogSearch extends FragmentDialogBase {
cbHeaders.setVisibility(View.VISIBLE); cbHeaders.setVisibility(View.VISIBLE);
cbHtml.setVisibility(View.VISIBLE); cbHtml.setVisibility(View.VISIBLE);
} }
if (account < 0) { if (folder < 0) {
cbSearchTrash.setVisibility(View.VISIBLE); cbSearchTrash.setVisibility(View.VISIBLE);
cbSearchJunk.setVisibility(View.VISIBLE); cbSearchJunk.setVisibility(View.VISIBLE);
} }

Loading…
Cancel
Save