mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-27 19:52:17 -05:00
Be more careful about deleting messages from the MessageListAdapter -
don't do it from something that's not the UI thread
This commit is contained in:
parent
4aba667a4e
commit
602099cfd3
@ -2287,6 +2287,8 @@ public class MessageList
|
||||
}
|
||||
}
|
||||
public void pruneDirtyMessages()
|
||||
{
|
||||
synchronized (mAdapter.messages)
|
||||
{
|
||||
Iterator<MessageInfoHolder> iter = mAdapter.messages.iterator();
|
||||
while (iter.hasNext())
|
||||
@ -2299,7 +2301,8 @@ public class MessageList
|
||||
mSelectedCount--;
|
||||
toggleBatchButtons();
|
||||
}
|
||||
iter.remove();
|
||||
mAdapter.removeMessage(holder);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user