Commit Graph

5645 Commits

Author SHA1 Message Date
cketti 1e628e7177 Reduce exposure of SingleMessageView internals 2015-01-16 23:37:37 +01:00
cketti 658657447e Fix viewing attachment with alternative MIME type 2015-01-16 23:37:37 +01:00
cketti de2eb25446 Use Glide for thumbnail generation + image loading 2015-01-16 23:37:37 +01:00
cketti cb94b5b192 Store attachment information in LocalBodyPart 2015-01-16 05:05:11 +01:00
cketti ac365567ee Replace dummy URI in AttachmentViewInfo instances
This is a first step towards fixing viewing of attachments.
2015-01-16 00:12:47 +01:00
cketti 41bd420213 Include database ID in message parts reconstructed from the database 2015-01-15 23:48:11 +01:00
cketti 8fce9e3654 Move functionality from AttachmentView to AttachmentController 2015-01-15 11:37:23 +01:00
cketti 087238f507 Move AttachmentView to 'messageview' package 2015-01-15 08:25:43 +01:00
cketti 2e05127c97 Use a Loader to extract text of a message in a background thread 2015-01-14 09:58:31 +01:00
Jan Berkel ecd316d0af Simplify ImapConnection#connect 2015-01-14 04:41:21 +01:00
Jan Berkel 9523a589fc use `@Test(expected =` 2015-01-14 04:31:36 +01:00
Jan Berkel c79256684d simplify gradle config 2015-01-14 04:31:32 +01:00
Jan Berkel dfb025033d Convert remaining tests to JUnit4 2015-01-14 04:05:42 +01:00
Jan Berkel 4808406739 Make deleteCertificate null-safe 2015-01-14 03:45:09 +01:00
Jan Berkel 833d9c5de8 Base class is already annotated 2015-01-14 03:34:57 +01:00
Jan Berkel 79b03b5e4f Remove account after creation
* Avoid side-effects in static preferences which might interfere with other tests
2015-01-14 03:30:38 +01:00
Jan Berkel 4e964e271c Convert to JUnit4 test 2015-01-14 03:09:48 +01:00
Jan Berkel 0153766dd5 Convert to JUnit4 2015-01-14 03:09:00 +01:00
Jan Berkel 0f312f012e Create test mailboxes 2015-01-14 03:08:44 +01:00
Jan Berkel 055d4104b7 log ChangeLog click failure 2015-01-13 16:12:39 +01:00
Jan Berkel a15583a080 Start server early 2015-01-13 15:52:31 +01:00
Jan Berkel de4b6d1076 Merge pull request #531 from jberkel/imap-tests
Update greenmail + add more tests
2015-01-13 11:43:07 +01:00
Jan Berkel bdbe976396 Test connection w/o server 2015-01-13 10:09:42 +01:00
Jan Berkel e98f323222 Initialize settings in setUp() 2015-01-13 10:05:15 +01:00
Jan Berkel f7da704007 WS 2015-01-13 09:34:13 +01:00
cketti 78ed2a23b1 Use a Loader to load the message to view from the database 2015-01-13 04:17:25 +01:00
Jan Berkel 60070b7883 Add more tests + descriptive names 2015-01-13 01:59:51 +01:00
Jan Berkel 111212b391 Setup and tear down server between tests 2015-01-13 01:11:09 +01:00
Jan Berkel 7958467503 Convert from thread to AsyncTask for espresso tests 2015-01-13 01:11:09 +01:00
Jan Berkel b481d3f978 Adding tests for IMAP connection, use greenmail snapshot 2015-01-13 01:10:56 +01:00
cketti 787c014265 Create new package for UI code related to message viewing 2015-01-12 22:46:56 +01:00
cketti 1bf159a300 Get rid of unused LocalTextBody 2015-01-12 22:09:55 +01:00
cketti bcd64017e3 Extract text to display before viewing the message 2015-01-12 21:52:44 +01:00
cketti 4db57dfc85 Merge pull request #529 from k9mail/ignore_meta_refresh
Sanitize HTML to remove meta refresh
2015-01-11 11:35:06 +01:00
cketti 63abf05776 Sanitize HTML to remove meta refresh
Using
  <meta http-equiv="Refresh" content="1; URL=http://example.com/">
in a HTML message causes WebView to load the URL in the default browser.
Overriding WebViewClient.shouldOverrideUrlLoading() allows us to cancel
loading this URL. Sadly, I found no way to find out whether the method was
called because of a meta refresh or because the user clicked on a link.

So now we're using HtmlCleaner to parse the HTML and remove all "meta" elements
containing an "http-equiv" attribute with a value of "refresh".
2015-01-11 11:29:53 +01:00
cketti 2532362ed5 Add test for updating a message with a missing part 2015-01-10 04:39:02 +01:00
cketti bd97004ebd Fix downloading/saving single message parts 2015-01-10 04:38:57 +01:00
cketti 743e640d8c Remove references to 'text_content' and 'html_content' 2015-01-10 01:22:39 +01:00
cketti ce862c88f8 Change AttachmentProvider to use the new database structure 2015-01-07 02:34:44 +01:00
cketti e5f0bec6bc Get rid of "backward compatibility" in AttachmentProvider 2015-01-07 00:16:37 +01:00
cketti c5ba202a56 Code style fixes 2015-01-07 00:13:28 +01:00
cketti 34b5d56ab1 Get rid of 'attachments' table 2015-01-06 23:59:58 +01:00
cketti 1a5ecfea1d Also delete local messages when using "clear messages" on an account
We have been throwing away all attachments already, so it doesn't make
too much sense to keep local messages. And when we're not keeping local
messages we can remove all entries from the 'threads' table.
2015-01-06 23:48:22 +01:00
cketti 30e37000f9 Remove remnants of the "headers" table 2015-01-06 21:36:31 +01:00
cketti d7edb0ed4f Minimal version that reconstructs original message from the database
This change breaks all kinds of things, e.g.
- deleting messages
- updating messages
- downloading attachments
- deleting attachments
- searching in message bodies
2015-01-06 03:20:38 +01:00
Jan Berkel c7229e4724 Enable lint checks for k9mail-library 2015-01-05 23:26:36 +01:00
cketti 523ebd0f2a Remove 'dirty' check for LocalMessage 2015-01-05 02:25:17 +01:00
cketti 3eb25a011f Don't automatically create Message-ID when none is found 2015-01-05 02:25:17 +01:00
cketti d7085a2f07 Properly decode the body in MessageExtractor.getTextFromPart() 2015-01-05 00:57:25 +01:00
cketti abbad18283 Code style fixes 2015-01-05 00:45:05 +01:00