Previously the activity theme was used to display the auto-complete
suggestions. This lead to unreadable text when the activity theme was
different from the "composer theme".
This was disabled in faa666394c
because it isn't possible to extract the name of the android
contact in the 'ORDER BY...' clause when querying the database.
Instead it simply sorts by the email address.
This may cause the same contact to appear multiple times in
the list, if they have multiple email addresses assigned.
But in most cases this is good enough and surely better than
not having the option to sort by sender at all.
Desktop mail clients such as Thunderbird also simply use the
sender email information when sorting the column.
This also adds a SenderComparator for usage in the MergeCursor.
Seemingly the intents in the task back stack got confused when the
pending intent was updated in those versions (the Accounts intent was
delivered to MessageList). Avoid that by not updating the current
intent, but dropping the old one.
Fixes issue #4955.
Previously messages in the local Trash folder were marked as deleted,
then deleted from the server. During the next sync the placeholders for
deleted messages are removed from the database.
Obviously this doesn't work for POP3 accounts because the Trash folder
can't be synchronized with the server. So, for POP3, we now immediately
clear out all messages in that folder.
The server search itself does work. But the results are not displayed
to the user because only the message headers of found messages are
downloaded and the subsequent search in the local database won't return
those messages.
This requires another database schema change. With this change messages
at the root of a thread reference themselves in the 'threads' table,
i.e. 'root' contains the value of 'id' for these messages. It makes
selecting all messages in a thread much simpler.