mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-11 20:15:03 -05:00
Fix message list when no search condition is given (All messages)
This commit is contained in:
parent
f093b84142
commit
93ef3a7b0f
@ -2649,6 +2649,10 @@ public class MessageListFragment extends SherlockFragment implements OnItemClick
|
||||
private void buildQuery(Account account, ConditionsTreeNode node, StringBuilder query,
|
||||
List<String> selectionArgs) {
|
||||
|
||||
if (node == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (node.mLeft == null && node.mRight == null) {
|
||||
SearchCondition condition = node.mCondition;
|
||||
switch (condition.field) {
|
||||
|
@ -295,7 +295,12 @@ public class LocalSearch implements SearchSpecification {
|
||||
* very dirty fix for remotesearch support atm
|
||||
*/
|
||||
public String getRemoteSearchArguments() {
|
||||
for (ConditionsTreeNode node : getLeafSet()) {
|
||||
Set<ConditionsTreeNode> leafSet = getLeafSet();
|
||||
if (leafSet == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
for (ConditionsTreeNode node : leafSet) {
|
||||
if (node.getCondition().field == Searchfield.SUBJECT ||
|
||||
node.getCondition().field == Searchfield.SENDER ) {
|
||||
return node.getCondition().value;
|
||||
|
Loading…
Reference in New Issue
Block a user