1
0
mirror of https://github.com/moparisthebest/k-9 synced 2024-08-13 17:03:48 -04:00
Commit Graph

3201 Commits

Author SHA1 Message Date
cketti
bd3bd861c5 Optimize code to extract the character to display in the fallback contact picture 2013-08-21 13:08:05 +02:00
cketti
ce56475a4f Avoid race condition that can lead to a NullPointerException 2013-08-21 12:33:27 +02:00
cketti
f11f0fcc9b Skip incorrectly formatted/parsed LSUB/LIST replies
Example: * LIST (\HasChildren) "." [Folder]
"[Folder]" will be parsed as list containing the element "Folder".
2013-08-20 18:39:20 +02:00
cketti
4fe6f90428 Use Google's fix for the PRNG mess
Source: http://android-developers.blogspot.de/2013/08/some-securerandom-thoughts.html
2013-08-16 19:49:30 +02:00
cketti
20fcd6f63d Add setting to toggle colored background of fallback contact pictures 2013-08-16 18:43:00 +02:00
cketti
3064d8ab31 Code style and documentation cleanup 2013-08-16 01:49:26 +02:00
Joe Steele
b7c67019af SMTP dot stuffing should be done *after* line wrapping. 2013-08-13 19:27:40 -04:00
Joe Steele
564195bad9 Close stream when done (StrictMode error) 2013-08-09 19:17:07 -04:00
cketti
d8030eaa7c Make sure Account.getDescription() never returns null
Fixes issue 5857
2013-08-10 00:08:18 +02:00
Joe Steele
fcabb7395d bug fix: use "1" not "true" for SQL boolean
Ref:  Pull request #355 from @edemaine
2013-08-02 13:01:22 -04:00
Joe Steele
2df436e7bc Close stream when done (StrictMode error). 2013-08-02 12:56:10 -04:00
Joe Steele
fce39f0fce HTML tag cleanup
Effective with earlier commit e2c5229e85,
messages are wrapped with <html> tags at display time, rather than
when messages are saved.

For consistency, this commit removes tags from a status message, because
they, too, will be added back at display time.

Closes pull request 286.
2013-08-01 19:38:48 -04:00
Jesse Vincent
2ba84bceaa Merge pull request #353 from sfuhrm/gmail-style-user-pics
Gmail style user pics, 2nd try

* sfuhrm/gmail-style-user-pics:
  Changed the fallback char from 'K' to '?'. The riddler was here ;).
  Using Android proposed colors as contact color palette now: http://developer.android.com/design/style/color.html
  Fixed NPE found by blackbox87 ... thanks pal!
  Added more finer characters as proposed by cketti
  Caching also the calculated anonymous bitmap as proposed by maniac103. This removes a lot of code for special handling unknown contacts.
  Bugfix for negative modulo result indexing the palette array
  Changed hash based color calc to a hash indexed palette as discussed in the pull request.
  GMail-app-style generated colorful one-letter contact pictures for pictureless contacts

Conflicts:
	src/com/fsck/k9/activity/misc/ContactPictureLoader.java
	src/com/fsck/k9/fragment/MessageListFragment.java
2013-07-30 22:00:19 -04:00
Jesse Vincent
bbad298bf6 Convert OpenMode from an Enum to static ints for perf improvement.
(Based on profiling of long folder list opens)

This should be backported to 4.4
2013-07-30 21:32:35 -04:00
Jesse Vincent
e9a0cbb269 Ask SQLite for a simpler calculation when counting unread messages. The docs imply this is a decent perf win. I'm seeing at least a bit of one 2013-07-30 21:32:35 -04:00
Stephan Fuhrmann
c30af244cf Changed the fallback char from 'K' to '?'. The riddler was here ;). 2013-07-30 21:27:52 +02:00
Stephan Fuhrmann
ea5905861a Using Android proposed colors as contact color palette now: http://developer.android.com/design/style/color.html 2013-07-30 21:27:52 +02:00
Stephan Fuhrmann
393f45bda1 Fixed NPE found by blackbox87 ... thanks pal! 2013-07-30 21:27:52 +02:00
Stephan Fuhrmann
6af02c4c13 Added more finer characters as proposed by cketti 2013-07-30 21:27:52 +02:00
Stephan Fuhrmann
df5766ba3a Caching also the calculated anonymous bitmap as proposed by maniac103. This removes a lot of code for special handling unknown contacts. 2013-07-30 21:27:52 +02:00
Stephan Fuhrmann
d45c8b053b Bugfix for negative modulo result indexing the palette array 2013-07-30 21:27:52 +02:00
Stephan Fuhrmann
64212072c0 Changed hash based color calc to a hash indexed palette as discussed in the pull request. 2013-07-30 21:27:52 +02:00
cketti
e6d6744f55 Rename string to better convey the meaning
notification_action_read -> notification_action_mark_as_read
2013-07-23 20:12:48 +02:00
Wang Li
231367b448 required exception class 2013-07-23 14:17:11 +08:00
Wang Li
50a8d89468 remoteStore assocciated with account indirectly should also be reseted when acccount was removed. Otherwise, there might be residual data that will affec account being added later. 2013-07-23 14:09:53 +08:00
Jesse Vincent
917da8cd90 Fix for market-reported NPE:
java.lang.NullPointerException
at com.fsck.k9.controller.MessagingController.actOnMessages(MessagingController.java:5602)
at com.fsck.k9.controller.MessagingController.deleteThreads(MessagingController.java:3986)
at com.fsck.k9.fragment.MessageListFragment.onDelete(MessageListFragment.java:1311)
at com.fsck.k9.fragment.MessageListFragment.onDelete(MessageListFragment.java:1306)
at com.fsck.k9.fragment.MessageListFragment.onContextItemSelected(MessageListFragment.java:1506)
at android.support.v4.app.Fragment.performContextItemSelected(Fragment.java:1583)
at android.support.v4.app.FragmentManagerImpl.dispatchContextItemSelected(FragmentManager.java:1992)
at android.support.v4.app.FragmentActivity.onMenuItemSelected(FragmentActivity.java:370)
at com.actionbarsherlock.app.SherlockFragmentActivity.onMenuItemSelected(SherlockFragmentActivity.java:211)
at com.android.internal.policy.impl.PhoneWindow$DialogMenuCallback.onMenuItemSelected(PhoneWindow.java:4038)
at com.android.internal.view.menu.MenuBuilder.dispatchMenuItemSelected(MenuBuilder.java:735)
at com.android.internal.view.menu.MenuItemImpl.invoke(MenuItemImpl.java:149)
at com.android.internal.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:874)
at com.android.internal.view.menu.MenuDialogHelper.onClick(MenuDialogHelper.java:193)
at com.android.internal.app.AlertController$AlertParams$3.onItemClick(AlertController.java:934)
at android.widget.AdapterView.performItemClick(AdapterView.java:301)
at android.widget.AbsListView.performItemClick(AbsListView.java:1287)
at android.widget.AbsListView$PerformClick.run(AbsListView.java:3078)
at android.widget.AbsListView$1.run(AbsListView.java:4161)
at android.os.Handler.handleCallback(Handler.java:615)
at android.os.Handler.dispatchMessage(Handler.java:92)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:4921)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1038)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:805)
at dalvik.system.NativeStart.main(Native Method)
2013-07-21 15:54:46 -04:00
Stephan Fuhrmann
16f6d85ea2 GMail-app-style generated colorful one-letter contact pictures for pictureless contacts 2013-07-21 14:34:45 -04:00
Stephan Fuhrmann
3feaeb6903 GMail-app-style generated colorful one-letter contact pictures for pictureless contacts 2013-07-21 16:58:38 +02:00
Jesse Vincent
6c3fb46541 only show the super-condensed layout if the contact picture is not being displayed. 2013-07-21 09:20:40 -04:00
Jesse Vincent
86ec4b32e9 restore super-dense layout when the user has selected 0 lines of message preview 2013-07-20 14:53:39 -04:00
Jesse Vincent
1fa6d5f960 Add an index for a heavy query 2013-07-18 20:09:39 -04:00
Jesse Vincent
4bd6f36eb9 Don't invalidate the options menu from the message list as we open a
message. We also invalidate it (twice) as we show the message. It turns
out to have measurable performance impact on 2.3 thanks to ABS
2013-07-17 19:52:18 -04:00
Jesse Vincent
767352515f Cache our compat lookups for our message webview - (They're expensive on
older devices - and pointless not to reuse)
2013-07-17 18:33:19 -04:00
cketti
dda8395c7a Make sure we always have the ID of a folder when fetching the unread/flagged count 2013-07-16 16:54:26 +02:00
cketti
9a5fca2d16 Stop using the old Android Market URL 2013-07-16 16:24:51 +02:00
Jesse Vincent
876d478ad7 Opening a folder (especially in threaded mode) does a very heavy SQL query. This method doesn't use or modify the folder object. Don't cargo-cult the Open here.
(cketti may well tell me I'm wrong about this. Happy to listen & fix)
2013-07-11 18:44:44 -04:00
Jesse Vincent
bcc2263e07 Marking a message as read in the database is currently very expensive, especially if you have threading enabled.
Defer that until _after_ telling listeners that they're cool to show the message
2013-07-11 18:44:44 -04:00
Jesse Vincent
1bed455e4f Replace synchronous setting of a flag with async setting of the flag. This helps speed up message display time (anecdotally) 2013-07-11 18:44:44 -04:00
cketti
186f6d6ba2 Don't save signature to identity header if identity doesn't use a signature 2013-07-08 06:44:44 +02:00
cketti
306b258f25 Merge pull request #323 from jca02266/adapt_broken_server
Adapt broken pop3 server
2013-07-07 19:43:55 -07:00
cketti
5d07b6691b Don't load unread/flagged count when creating LocalFolder instances
This avoids a potentially expensive LEFT JOIN when querying the database.
2013-07-07 03:31:14 +02:00
cketti
422ba279b5 Refactor code to create LocalFolder instances from a database query. 2013-07-07 03:31:14 +02:00
cketti
82c0a92049 Fix actions started from the message list context menu
This patch makes sure actions started via the context menu operate on
the correct message even when the message list changes and the 'adapter
position' accessible via the menu object points to another message.
When the message the menu was opened for is deleted the context menu
will be closed.
2013-07-04 02:59:00 +02:00
cketti
ed6eb7bade Fix code to reset the database when upgrading fails
Previously the app crashed when upgrading the database failed. Now we
reset the database version and run the upgrade code again (recreating
all tables).
2013-07-03 05:25:39 +02:00
cketti
1c6072a1cc Fix "Folders" menu item and hotkey handling in MessageList 2013-07-02 20:03:45 +02:00
Jesse Vincent
b4c8afbe22 better guarding for the folders menu item in the face of search folders with multiple accounts 2013-07-02 13:14:43 -04:00
Jesse Vincent
b7cf3e421a Play store NPE:
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.fsck.k9/com.fsck.k9.activity.UpgradeDatabases}: java.lang.NullPointerException
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2117)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2155)
at android.app.ActivityThread.access$700(ActivityThread.java:139)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1248)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:5062)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:795)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:558)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.NullPointerException
at android.app.Instrumentation.execStartActivity(Instrumentation.java:1409)
at android.app.Activity.startActivityForResult(Activity.java:3389)
at android.app.Activity.startActivityForResult(Activity.java:3350)
at android.app.Activity.startActivity(Activity.java:3562)
at android.app.Activity.startActivity(Activity.java:3528)
at com.fsck.k9.activity.UpgradeDatabases.launchOriginalActivity(UpgradeDatabases.java:183)
at com.fsck.k9.activity.UpgradeDatabases.onCreate(UpgradeDatabases.java:109)
at android.app.Activity.performCreate(Activity.java:5058)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1079)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2081)
... 11 more
2013-07-01 23:32:04 -04:00
Jesse Vincent
0a029561d1 Back, by popular demand, an empty trash button in the accounts context menu 2013-06-30 18:54:27 -04:00
Jesse Vincent
4baaafcd88 Add a "Folders" menu item back to the message list to ease nav discoverability 2013-06-30 18:54:13 -04:00
Jesse Vincent
fa1b7dec31 broaden a 'catch' to catch other failures showing all headers.
Market reported NPE:

java.lang.NullPointerException
at com.fsck.k9.view.MessageHeader.showAdditionalHeaders(MessageHeader.java:186)
at com.fsck.k9.view.MessageHeader.onShowAdditionalHeaders(MessageHeader.java:318)
at com.fsck.k9.fragment.MessageViewFragment.onToggleAllHeadersView(MessageViewFragment.java:300)
at com.fsck.k9.activity.MessageList.onOptionsItemSelected(MessageList.java:867)
at android.support.v4.app.Watson.onMenuItemSelected(Watson.java:119)
at com.actionbarsherlock.ActionBarSherlock.callbackOptionsItemSelected(ActionBarSherlock.java:603)
at com.actionbarsherlock.internal.ActionBarSherlockNative.dispatchOptionsItemSelected(ActionBarSherlockNative.java:78)
at com.actionbarsherlock.app.SherlockFragmentActivity.onMenuItemSelected(SherlockFragmentActivity.java:205)
at com.android.internal.policy.impl.PhoneWindow.onMenuItemSelected(PhoneWindow.java:1047)
at com.android.internal.view.menu.MenuBuilder.dispatchMenuItemSelected(MenuBuilder.java:735)
at com.android.internal.view.menu.MenuItemImpl.invoke(MenuItemImpl.java:149)
at com.android.internal.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:874)
at com.android.internal.view.menu.ListMenuPresenter.onItemClick(ListMenuPresenter.java:180)
at android.widget.AdapterView.performItemClick(AdapterView.java:301)
at android.widget.AbsListView.performItemClick(AbsListView.java:1276)
at android.widget.AbsListView$PerformClick.run(AbsListView.java:3067)
at android.widget.AbsListView$1.run(AbsListView.java:3963)
at android.os.Handler.handleCallback(Handler.java:615)
at android.os.Handler.dispatchMessage(Handler.java:92)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:4898)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1006)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:773)
at dalvik.system.NativeStart.main(Native Method)
2013-06-30 18:52:27 -04:00
Jesse Vincent
2ef5c11e9b market-reported NPE
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.fsck.k9/com.fsck.k9.activity.MessageList}: java.lang.NullPointerException
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1970)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1995)
at android.app.ActivityThread.access$600(ActivityThread.java:128)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1161)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:4517)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:993)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:760)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.NullPointerException
at com.fsck.k9.activity.MessageList.decodeExtras(MessageList.java:368)
at com.fsck.k9.activity.MessageList.onCreate(MessageList.java:216)
at android.app.Activity.performCreate(Activity.java:4470)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1053)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1934)
k
2013-06-30 18:52:17 -04:00
Koji Arai
b88fbb7fd8 adapt to a corner case for broken server. 2013-06-29 22:28:27 +09:00
cketti
85e7d4fa12 Don't crash when MessageList is started with no intent extras 2013-06-29 03:22:44 +02:00
Koji Arai
35c79a5656 adapt broken pop3 server 2013-06-26 23:57:55 +09:00
cketti
b03b487d62 Remove contacts helper code specific to SDK 7 2013-06-25 22:47:47 +02:00
cketti
2789e9fa38 Don't use extended notifications when privacy mode is enabled 2013-06-17 16:26:49 +02:00
cketti
6a6bb95ad4 Only enable debug logging when running a debuggable build
There have been some complaints from Android developers that get flooded
by K-9's log messages when debugging their own apps. Oops :)
2013-06-09 02:39:47 +02:00
cketti
cb906ee6a4 Use the color chip area as click target for the multi-select checkboxes 2013-06-07 07:12:23 +02:00
Joe Steele
769ad843dd Revert "Fix for StrictMode error."
This reverts commit bbdec62e37.

Aside from being the incorrect solution for fixing the problem
described in pull request 211, the patch generates 'Dead code'
warnings inside the if(){} statements on lines 46 and 47.

The correct fix for the problem was already implemented in commit
5678786c97.

Although the logcat in the pull request was generated after the fix,
line numbers in the log indicate that it was based on an outdated
version of MimeUtility.java from before the fix.
2013-06-03 11:59:58 -04:00
cketti
34812fa5b8 Correctly initialize mSingleAccountMode
This fixes a NullPointerException when trying to open account settings
from the Unified Inbox (when there's only one account).
2013-05-27 16:59:07 +02:00
cketti
f16082eab3 Always include currently opened message in the message list
This should fix various bugs where moving to the next/previous message
didn't work.
2013-05-23 17:15:09 +02:00
cketti
79059e30da Remove override annotation so we can use the latest SDK to compile 2013-05-23 16:45:19 +02:00
Koji Arai
f87ff20556 Merge pull request #309 from jca02266/preserve-spaces
Fixed issue 5630: Quotes are missing a space between > and the quoted text
2013-05-15 21:24:29 -07:00
Koji Arai
4dcf50d127 Re-desined textToHtml() according to the state transition diagram. 2013-05-11 08:44:17 +09:00
Koji Arai
6c4461cd13 Fix to preserve spaces 2013-05-09 23:08:11 +09:00
Koji Arai
fa80313f6b Should preserve spaces at first of line. 2013-05-09 22:11:50 +09:00
Joe Steele
acfc3e0f63 Fix settings versioning after merging autofitWidth branch.
Versioning on master was updated subsequent to the creation
of the branch.
2013-05-08 23:10:01 -04:00
Jesse Vincent
2e74d28da9 Merge branch 'Issue_4503_auto-fit_messages_option' of https://github.com/zjw/k-9 into zjw-Issue_4503_auto-fit_messages_option
* 'Issue_4503_auto-fit_messages_option' of https://github.com/zjw/k-9:
  Revert "Don't show a disabled preference if there is nothing a user can do to enable it."
  Fix indentation
  Correct preference version number.
  Issue 4503: Auto-fit messages option
  Don't show a disabled preference if there is nothing a user can do to enable it.
2013-05-07 21:49:12 -04:00
cketti
edf75ec05a Fix crash on search with multiple accounts set up 2013-05-05 03:03:40 +02:00
Joe Steele
97a2f1b261 Revert "Don't show a disabled preference if there is nothing a user can do to enable it."
This reverts commit 0ecc49815f because
an equivalent commit was subsequently made to master:
5f49195a0a
2013-04-28 13:37:29 -04:00
cketti
c7024af9a1 Merge branch 'message-list-sender-sorting' 2013-04-26 02:39:48 +02:00
cketti
99daa4068f Merge branch 'better_singleaccount_check' 2013-04-26 02:37:19 +02:00
cketti
46ed21d9f5 Merge branch 'smtp_port_fix' 2013-04-26 02:30:27 +02:00
cketti
b91b86c657 Change SMTP default port to 587 2013-04-26 02:29:36 +02:00
cketti
1c722876f1 Use very light grey instead of white for message text in dark theme 2013-04-24 01:05:11 +02:00
cketti
d14bdc0b79 Exclude folders Trash, Spam, and Outbox from "All messages" 2013-04-23 20:14:29 +02:00
cketti
8c8e0d299d Fix copyOrMove() so it works for single messages in Unified Inbox 2013-04-23 19:25:05 +02:00
cketti
8f9dd78012 Always enable "pull to refresh" when "check mail" action is shown 2013-04-23 18:55:24 +02:00
dzan
6c1b3cbc68 Change smtp+tls default port to 587. 2013-04-20 18:02:30 +02:00
cketti
5f49195a0a Hide "condensed layout" setting instead of disabling it 2013-04-19 02:24:41 +02:00
cketti
e15409bafa Don't show ALL unread messages for "notification opens unread messages" 2013-04-18 22:06:33 +02:00
cketti
0d80dd8fe1 Avoid another NPE 2013-04-18 05:49:18 +02:00
cketti
51ad31a513 Avoid NullPointerException 2013-04-18 05:43:11 +02:00
cketti
4890cd9ea0 Better cope with messages having identical message IDs 2013-04-17 02:09:43 +02:00
cketti
d29825fe57 Fix settings file versioning 2013-04-16 01:21:26 +02:00
dzan
33cf1bc222 If messagelist started from Unified localsearch, verify if we are really dealing with multiple accounts. If not then set SingleAccountMode anyway. 2013-04-14 14:47:45 +02:00
Joe Steele
84769d2433 Fix indentation 2013-04-11 22:26:32 -04:00
Joe Steele
aedbe46975 Correct preference version number.
New number should match updated Settings.VERSION
2013-04-05 11:02:20 -04:00
Joe Steele
d9979cb1a2 Issue 4503: Auto-fit messages option
Create a preference option to automatically shrink messages
to fit the screen width (default setting is "shrink").
2013-04-04 17:11:17 -04:00
Joe Steele
0ecc49815f Don't show a disabled preference if there is nothing a user can do to enable it. 2013-04-04 16:48:54 -04:00
Jesse Vincent
f363333c87 simplify the messagelist chips based on lots of user screaming. default checkboxes to being on. 2013-04-02 23:49:06 -04:00
cketti
175e29b71d Make status display less awkward when checking mail from Unified Inbox
We really need to fix the ActivityListener madness :(
2013-04-03 03:08:06 +02:00
cketti
b096c2bf19 Fix unread count in notifications (again) 2013-04-02 21:47:37 +02:00
cketti
c5dc626bbc Show "check mail" action when displaying Unified Inbox etc. 2013-04-02 21:47:20 +02:00
cketti
0c5bdf2c97 Add "Mark all as read" action to message list 2013-04-02 19:17:58 +02:00
cketti
002e3dd538 Avoid IllegalStateException
Reported for Kaiten:
java.lang.IllegalStateException: Can not perform this action after
onSaveInstanceState
...
at android.support.v4.app.DialogFragment.dismiss
2013-04-02 04:02:54 +02:00
cketti
9d7eae252e Avoid NullPointerException 2013-04-02 04:02:25 +02:00
cketti
0ba4bf6973 Fix NPE when fragment detached from activity 2013-04-02 04:02:24 +02:00
cketti
bc665bffe1 Fix NPE introduced in 340d6e0522 2013-03-31 16:53:27 +02:00
cketti
48c3fbd2ba Don't crash when being started by an old unread widget intent 2013-03-31 01:35:38 +01:00
cketti
33a2b05701 Get rid of accidentally created "-NONE-" folder 2013-03-31 01:13:09 +01:00
cketti
f95e64f766 Don't create folder -NONE- when excluding special folders from a search 2013-03-31 01:02:31 +01:00
cketti
ce0308f528 Avoid NullPointerException in SubjectComparator 2013-03-31 00:48:01 +01:00
cketti
c4799d20f0 Fix condition on when to show "check mail" in POP3 accounts 2013-03-31 00:24:28 +01:00
cketti
340d6e0522 Use themed context when creating EmailAddressAdapter
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".
2013-03-28 19:36:41 +01:00
m0viefreak
d85af1bfe0 reenable sorting by sender in messagelist
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.
2013-03-27 13:08:42 +01:00
cketti
2fc3909ec3 Fix NullPointerException 2013-03-22 19:51:58 +01:00
cketti
597e954798 Avoid NullPointerException (reported via Play Store) 2013-03-21 23:19:11 +01:00
cketti
9ea46cf03b Merge branch 'Issue_4019_pinch_zoom'
Conflicts:
	src/com/fsck/k9/view/MessageWebView.java
2013-03-19 21:09:23 +01:00
cketti
55ca846ced Avoid NullPointerException when message contains no subject 2013-03-19 03:08:18 +01:00
cketti
9118097dcb Avoid NullPointerException when decoding contact pictures 2013-03-19 02:59:05 +01:00
cketti
1c75590e7a Fix crash due to ambiguous column name in SORT clause 2013-03-19 02:32:47 +01:00
cketti
aff9bec92b Work around a bug in ListView 2013-03-18 22:56:56 +01:00
cketti
94b5758eea Use cache when marking message as read on view 2013-03-18 17:53:18 +01:00
cketti
a364d6262d Fix cache cleanup 2013-03-18 17:44:33 +01:00
Danny Baumann
538b81b6ec Make notification task back stack consistent to activity flow.
Fixes #4956.
2013-03-15 13:25:25 +01:00
Danny Baumann
195686cbd6 Fix NPE when clicking on a notification with >= 2 messages on SDK < 16.
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.
2013-03-15 12:48:04 +01:00
cketti
b4c599d514 Merge pull request #281 from k9mail/fix_webview_autoscroll
Hack around WebView's initial auto-scrolling past the message header
2013-03-13 19:22:05 -07:00
cketti
a3802a7a8e Only Jelly Bean seems to have the auto-scroll issue 2013-03-14 03:19:42 +01:00
Danny Baumann
3ff522c9c4 Include a full activity back stack when building notification intents. 2013-03-13 11:03:51 +01:00
Danny Baumann
d523caa61b Also clear back stack when a new intent arrives.
This should make sure there aren't any old fragment instances in that
case.
2013-03-13 11:03:51 +01:00
cketti
a619a9df93 Hide delete policy "Mark as read on server" for POP3 accounts 2013-03-13 06:34:14 +01:00
cketti
8dcc769c50 Hack around WebView's initial auto-scrolling past the message header 2013-03-12 07:54:38 +01:00
cketti
625c5f1874 Fix "Empty trash" functionality for POP3 accounts
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.
2013-03-10 21:45:36 +01:00
cketti
0319ee4a5d Move KOI8-U -> KOI8-R fixup to charset fall-back table 2013-03-10 09:55:25 +01:00
cketti
4b42d0e062 Code cleanup 2013-03-10 09:39:03 +01:00
eagan
c5802ed8ef Java5 style 'for' 2013-03-10 09:25:28 +01:00
eagan
a5f4ddae91 Enhancement for charset fallback.
Fallback rule is defined in CHARSET_FALLBACK_MAP.
Multi-level fallback is supported.
2013-03-10 09:25:13 +01:00
cketti
337487e2ae Merge pull request #211 from colund/master
Close stream in case of an exception
2013-03-10 00:11:53 -08:00
cketti
aea95b1493 Disable server side full text search for the moment
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.
2013-03-10 03:00:16 +01:00
cketti
658b5dbff6 Fix and vastly simplify the query for the threaded message list
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.
2013-03-08 01:15:26 +01:00
cketti
6b3a3f7ee0 Fix message list item background color 2013-03-07 00:11:05 +01:00
Danny Baumann
ae28b1aa38 Center folders without status (e.g. outbox) in folder list again. 2013-03-06 10:30:23 +01:00
cketti
f990e6f032 Fix indentation and code style 2013-03-06 07:53:39 +01:00
Uni-
323159ef97 Fix error duplicating false accounts when adding an account 2013-03-06 07:52:32 +01:00
cketti
4202ffe57d Merge branch 'improve_import' 2013-03-06 07:49:53 +01:00
cketti
7ff0da0b52 Refactor code to start Accounts activity to import settings 2013-03-06 06:26:04 +01:00
cketti
dc8cb3ba17 Fix indentation/code style 2013-03-06 06:16:07 +01:00
Uni-
4f5ab86be3 Add settings import on Welcome 2013-03-05 16:31:45 +09:00
Uni-
91a32e9c92 Fix NPE on isAccountNameUsed 2013-03-05 16:29:03 +09:00
cketti
754c0f2b93 Don't load resources when activity is not attached 2013-03-05 04:18:54 +01:00
cketti
c07f94e877 Fix NPE when moving a message from Unified Inbox (multiple accounts) 2013-03-05 04:09:47 +01:00
cketti
fe02f0c44a Avoid NPE reported via Play Store 2013-03-05 03:54:27 +01:00
cketti
df8ea306b8 Avoid NPE 2013-03-05 03:35:09 +01:00
cketti
e77c341542 Avoid NPE reported via Play Store 2013-03-05 03:31:18 +01:00
cketti
5270ebd629 Avoid NPE 2013-03-05 03:26:09 +01:00
cketti
41244ef448 Don't finish() MessageList when forwarding or replying to a message 2013-03-04 21:19:08 +01:00
cketti
78dc5e5194 Use different background for selected messages in message list 2013-03-03 22:52:03 +01:00
Joe Steele
c790fa73c1 Don't store the font-family preference with plain text messages.
Dynamically generate the CSS style for <pre> elements
for inclusion in the HTML <head> element when messages
are displayed.

This permits a user to change their font-family preference
for plain text messages and see the results immediately.

Obviously any old locally-stored messages that had their
font-family stored with them will continue to display using
that font-family, irrespective of the user's current
preference setting.
2013-03-01 18:48:46 -05:00
cketti
04e1bf6976 Restore code to remember the last direction messages were displayed in 2013-03-01 22:38:09 +01:00