Specify where to search

pull/153/head
M66B 6 years ago
parent b5b7f7a49c
commit 917fe43daa

@ -206,13 +206,21 @@ public class ViewModelBrowse extends ViewModel {
} }
if (keywords) if (keywords)
arg.writeAtom("OR"); arg.writeAtom("OR");
arg.writeAtom("TEXT"); arg.writeAtom("OR");
arg.writeAtom("OR");
arg.writeAtom("OR");
arg.writeAtom("FROM");
arg.writeBytes(state.search.getBytes());
arg.writeAtom("TO");
arg.writeBytes(state.search.getBytes());
arg.writeAtom("SUBJECT");
arg.writeBytes(state.search.getBytes());
arg.writeAtom("BODY");
arg.writeBytes(state.search.getBytes()); arg.writeBytes(state.search.getBytes());
if (keywords) { if (keywords) {
arg.writeAtom("KEYWORD"); arg.writeAtom("KEYWORD");
arg.writeBytes(state.search.getBytes()); arg.writeBytes(state.search.getBytes());
} }
arg.writeAtom("ALL");
Response[] responses = protocol.command("SEARCH", arg); Response[] responses = protocol.command("SEARCH", arg);
List<Integer> msgnums = new ArrayList<>(); List<Integer> msgnums = new ArrayList<>();

Loading…
Cancel
Save