1
0
mirror of https://github.com/moparisthebest/k-9 synced 2024-11-02 00:25:10 -04:00
Commit Graph

2416 Commits

Author SHA1 Message Date
Daniel Applebaum
ecc10e572f Fixes Issue 1224
Implement DEFLATE compression for IMAP communication, enabled by
default.  User can disable compression for Wi-Fi, Mobile, or Other
networks, if it causes problems or if uncompressed communication is
faster, which is possible on Wi-Fi and wired networks, especially.

"Other" is to allow for the Android platform to introduce new
networking types without having to immediately change K-9 Mail.
However, as those arise, new network types should be added as explicit
types in K-9 Mail.
2010-03-07 00:30:40 +00:00
Daniel Applebaum
c0e4220b82 Fixes Issue 1116
Fixes Issue 1278
Fixes Issue 119
Fixes Issue 1077
Fixes Issue 1238

Worked performed by danapple0 and cketti in
https://k9mail.googlecode.com/svn/k9mail/branches/issue1116

Add support for most batch ops (except move and copy) in search
results.  Add support for batch move and copy on real folders.

Increase efficiency of bulk IMAP moves and copies by doing as multiple
UID operations.

Eliminated serialization of Account objects.

Provide up-references in useful places to make all future code cleaner
and more efficient.

Fixed a bunch of draft handling

Merged from issue1116 branch, except for Account.java, which was
copied wholesale.  Account.java was manually merged in issue1116
branch at r1489

svn merge -r 1459:1489 https://k9mail.googlecode.com/svn/k9mail/branches/issue1116 .
cp ../issue1116/src/com/fsck/k9/Account.java src/com/fsck/k9/Account.java
2010-03-04 04:00:30 +00:00
Jesse Vincent
9e855c9ebd 2.511 2010-03-02 08:02:46 +00:00
cketti
6fb59467b7 Changed SmtpTransport.writeLine() to only use one OutputStream.write() call. Apparently some servers got the "be liberal in what you accept from others" part of the robustness principle wrong. When we used multiple calls in writeLine() (command + CR + LF) a separate TCP packet was send each time. It appears that those broken servers accepted the DATA command after DATA + CR and interpreted the LF as part of the actual data. This caused our headers to become part of the body because that LF was interpreted as the empty line that separates headers and body.
As a side effect of this fix sending mail could be slightly faster now due to less packets being sent.

Big thanks to Kevin Newland of Michigan Technological University for organizing a test account.

Fixes issue 799
2010-03-02 02:48:52 +00:00
Daniel Applebaum
97c7bf1d65 Hopeful (but untested code) to get updated capabilities after
successful CRAM-MD5 authentication.
2010-02-27 17:48:00 +00:00
Daniel Applebaum
f6e7d5d4c0 Fixes Issue 1252
Handle CAPABILITY response in following cases:
1) When sent as part of the banner, no longer sends explicit
CAPABILITY command

2) When sent as an UNTAGGED response to LOGIN, updates stored
   capabilities.

3) When sent as part of the TAGGED response to LOGIN, updates stored
   capabilities.

Due to odd implementation of the CRAM-MD5 authentication, the
capability updates will not happen as part of the CRAM-MD5
authentication.
2010-02-27 17:34:38 +00:00
Robert Jacob
8eb8e392ca Issue 1253
Updated german localization with new strings.
2010-02-24 22:50:33 +00:00
Robert Jacob
583d827c60 Don't let eclipse build the .svn directories. 2010-02-21 15:25:16 +00:00
Robert Jacob
366eda13f7 - Fixed project setup for Eclipse
- Removed Debug activity from manifest (activity class doesn't exist)
2010-02-21 15:19:11 +00:00
Bao-Long Nguyen-Trong
6b5ea9feda Reverted the revered version of AttachmentProvider so that people who used the attachment on sd card can still get to their attachments 2010-02-20 20:15:21 +00:00
cketti
ec3d9eb9ea Removed code from ImapStore.internalOpen() that tried to get the path delimeter before SELECTing a mailbox. This shouldn't be a problem since the delimeter
a) is already known if the server supports the NAMESPACE capability.
b) is included in the prefix anyway (=also known if namespace was set manually).
c) isn't needed when selecting a mailbox because we currently don't support folder hierarchy. So the delimeter is included in the folder name.

Fixes issue 1217
2010-02-20 01:07:38 +00:00
Jesse Vincent
f9d39e4814 Back out Attachments-on-SD support (it's on a feature branch now, while
Bao-Long makes it extra-awesome)

This commit should revert:
r1445
r1437
r1436
r1449
r1442
r1441
r1419
r1414
r1413
2010-02-18 03:28:31 +00:00
Bao-Long Nguyen-Trong
c5851f2866 Fixed issue 698: Set default attachment preview image in the code (and not only in layout) so that whne moving from a message to another we get the right preview 2010-02-16 06:53:02 +00:00
Jesse Vincent
7459f6cd26 2510 2010-02-16 00:25:14 +00:00
cketti
f7094a2a8e I broke email address validation with r1447. I changed EmailAddressValidator.isValid() to only accept email addresses without name part ('foo@bar.com' but not '"snafu" foo@bar.com') because AccountSetupBasics used it to verify the email address for an account. With the old validator spaces were allowed in the email field but lead to an exception later (issue 849). Unfortunately I missed the fact that there are implicit calls to isValid() to validate email addresses e.g. in the 'To field 2010-02-15 12:51:38 +00:00
Jesse Vincent
e6cabe4a82 2.509 2010-02-14 17:29:52 +00:00
Jesse Vincent
31459fa70a 2.508 2010-02-14 17:29:46 +00:00
cketti
51b92aaf80 Fixes issue 1225 2010-02-14 15:51:09 +00:00
cketti
6d84f199c5 Enforce maximum line length for 8-bit encoded messages transmitted via SMTP (998 characters + CRLF).
Fixes issue 1176
2010-02-13 23:45:45 +00:00
cketti
ab4e2ca2ec Commented out enhancements introduced in r1443 so we don't loose Android 1.5 support. 2010-02-13 19:35:47 +00:00
Bao-Long Nguyen-Trong
e435d9d616 Fixed issue 1205: Attachment storage location setting now takes effect immediatly. LocalStore is also better at handling when attachment are stored in a mix of internal and external storage (migration state after a setting change) 2010-02-13 19:07:10 +00:00
cketti
f2f3b4263d Fixed editable TextView 2010-02-13 18:20:08 +00:00
cketti
7b75b07f1f Fixes issue 849 2010-02-13 17:26:54 +00:00
Daniel Applebaum
2c3da067c3 Fixes Issue 1219
At cketti's suggestion, change the methodology for counting
server-side unread messages on an IMAP server from STATUS (UNSEEN) to
SEARCH UNSEEN NOT DELETED.  STATUS (UNSEEN) does not ignore DELETED
but unexpunged messages and leads to incorrect results.

http://www.mail-archive.com/c-client@u.washington.edu/msg00929.html
http://www.mail-archive.com/c-client@u.washington.edu/msg00931.html

This variant only checks for unread messages in the last 300 messages
in the folder, so will be wrong if there are unread messages earlier
in the folder.  However, it'll be more often correct than the old
version for the marjority of users.

Also, change the opening of folders for IMAP IDLE purposes to
read-only using EXAMINE instead of SELECT.
2010-02-13 17:02:27 +00:00
Daniel Applebaum
645ce28e18 Throwing the Exception will, at least, cause the exponential back-off
to take effect.
2010-02-13 15:14:28 +00:00
Daniel Applebaum
58048a4e19 Correct silly text error 2010-02-13 02:08:24 +00:00
cketti
ae12453a57 Implement support for android.intent.action.SEND_MULTIPLE (e.g. send multiple images from gallery)
Fixes issue 1210
2010-02-12 15:21:10 +00:00
Bao-Long Nguyen-Trong
6fe2dad5cc Added some defensive code to prevent crashes caused by the LocalStore getting in a bad state due to issue 1205 (still being worked on). This fixes issue 1214. 2010-02-11 21:16:37 +00:00
Bao-Long Nguyen-Trong
8d8233bcc0 Store attachment on sd card is now off by default (which is what it should have been in the first place) 2010-02-11 05:37:50 +00:00
cketti
2bd4f9632b Better handling of IMAP FETCH responses.
Fixes issue 1068
2010-02-10 13:52:25 +00:00
Daniel Applebaum
e83a428107 Far more advanced poll scheduler. Now it remembers that finish time
of the last successful periodic mail and computes the next start time
as an offset from that successful finish.  The ramifications of this
new method is that changing polling interval on an account does not
force delaying all accounts to poll next in the future by the new
interval.  Instead, K-9 Mail now adjusts the next poll time based on
what the next poll time should be based on the last poll finish and
the new interval.  

Example 1: In the old way, if the old polling interval was 1 hour, and
the next poll was 50 minutes away (10 minutes have passed), and you
changed the interval to 15 minutes, the poll would happen 15 minutes
from now.  In the new way, the next poll will happen only 5 minutes
from now, which is 15 minutes since the last poll.

Example 2: In the old way, if the old polling interval was 1 hour, and
the next poll was 10 minutes away (50 minutes have passed), and you
changed the interval to 30 minutes, the poll would happen 30 minutes
from now.  The next poll would then happen actually 80 minutes after
the previous poll completed.  In the new way, it'll actually happen
immediately, because the time for the next poll, based on the new
schedule, has already passed.

Similar scenarios happen when a loss of network connectivity
occurs. In the old way, polling would resume using the restoration of
connectivity as the starting point.  Each time network connectivity
was lost and restored, the next poll would be further delayed.  *If
connectivity was lost and restored frequently, a poll might never
happen!* In the new way, the next poll is rescheduled based on the
time of the last successful poll, so will be rescheduled just like it
was before the loss of connectivity.  If the time has already been
passed, the poll will happen immediately.
2010-02-10 06:18:35 +00:00
cketti
48c7189d03 Fix r1436 2010-02-09 16:57:30 +00:00
cketti
80ae0402e5 Fixes issue 1199 2010-02-09 15:41:40 +00:00
Daniel Applebaum
03a06696dc Pre-r660 we didn't have this line, and things worked better. Also see
Troy Engel's comments in Issue 936.  If this commit isn't
satisfactory, perhaps try Troy's suggestion.

Fixes Issue 936.
2010-02-09 03:34:49 +00:00
Daniel Applebaum
23e5a132d4 Provide title bar display of next polling time 2010-02-09 03:26:40 +00:00
Daniel Applebaum
c12f720ba0 Lower logging level for CoreService and provide instance class name. 2010-02-09 03:11:15 +00:00
Daniel Applebaum
49534f22fc Fixes Issue 834
Provide for setting Sent folder to -NONE- which suppresses actually
saving sent mail in any folder.

Also, eliminate logging which folders are not configured for pushing.
It was just too much logging.
2010-02-09 03:03:40 +00:00
Daniel Applebaum
790ae2e25c Fixes Issue 1194
Do both a poll and push reset when connectivity or background data
status changes.
2010-02-09 01:14:55 +00:00
cketti
7cafc8547b Removed unnecessary FIXME comment 2010-02-08 19:12:40 +00:00
cketti
033e0d40de Optional signatures on per identity basis. Original patch by jiri.tyr (thanks!) slightly modified by me.
Fixes issue 461
2010-02-08 17:47:00 +00:00
cketti
3b6cccdf7a Use Reflection to call WebSettings.setBlockNetworkLoads() to prevent info leaks via external resource loading.
Fixes issue 1183
2010-02-08 03:23:41 +00:00
cketti
58f3005a28 Removed duplicate shortcut/hotkey from forward (alternate) 2010-02-07 23:11:57 +00:00
cketti
20fc93c101 Updated german translation with patch from wertarbyte (thanks!).
(Poorly) translated missing strings (cketti)

Fixes Issue 1088
2010-02-07 23:02:07 +00:00
Daniel Applebaum
164ee7cbfd Fixes Issue 1059
Only reschedule polling and setup pushing when necessary due to
particular setting changes.  Makes the K-9 Mail UI much more
responsive to setting changes that do not affect polling and pushing.

The poll schedule is deliberately only rescheduled when the period is
decreased.  An increase in period will still allow the next scheduled
check to happen as originally scheduled.
2010-02-07 21:23:33 +00:00
Daniel Applebaum
2f8f52fb0b Fixes Issue 1112
Fixes Issue 1034

Refresh Account from Preferences, so that it'll have a fresh copy of
all information.  Failure to do this caused the AccountSettings
Activity to show stale information when invoked repeatedly from the
same prior Activity.
2010-02-07 16:05:29 +00:00
Bao-Long Nguyen-Trong
c497485b2f Better message flag management so that we don't end up with (POP3) messages having both X_DOWNLOADED_FULL and X_DOWNLOADED_PARTIAL 2010-02-07 06:05:11 +00:00
Bao-Long Nguyen-Trong
46bff831d1 Using X_DOWNLOADED_FULL flag instead of the X_DOWNLOADED_PARTIAL on to determine if we need to show the downloading icon. Some POP3 messages carry both flags. 2010-02-07 06:00:28 +00:00
Bao-Long Nguyen-Trong
131280c3f2 Still init LocalStore.mExternalAttachmentsDir even if sd card is not ready so that the object does not end up in a bad state 2010-02-07 05:58:04 +00:00
Daniel Applebaum
1fb03a45a0 Fixes Issue 1059
Provides for menu items to quickly change the mode of displayed
folders.  Also, reorganizes the menu to have an Advanced sub-menu,
like Accounts page has.

Desparately needs a new icon for the Folders menu item.
2010-02-06 23:23:22 +00:00
Daniel Applebaum
4fa4f22f2c Fixes Issue 494
Allow for setting the Outbox to have any name, as tying it to a server
side folder does not make sense.  It is never synced.
2010-02-06 22:36:22 +00:00