Commit Graph

1095 Commits

Author SHA1 Message Date
B. Petersen 13723e9f9f add more tests 2019-11-17 15:50:09 +01:00
B. Petersen 3c8ca66d0d test sql-string literals 2019-11-17 15:39:23 +01:00
björn petersen a4a1cd42db Merge pull request #844 from deltachat/move-location-to-trash
Delete msg related POI when message is deleted
2019-11-16 17:40:53 +01:00
Alexander Krotov 69e14dcb2d Replace some magic numbers with constants 2019-11-16 16:08:08 +00:00
Nico de Haen e2673894b4 Delete message only if its a POI 2019-11-16 16:55:13 +01:00
B. Petersen 852b16c972 target comment of @flub 2019-11-16 13:55:59 +01:00
B. Petersen 5796c28391 test contact adding and modifying 2019-11-16 13:55:59 +01:00
holger krekel b6095e29d7 Update src/pgp.rs 2019-11-16 13:53:47 +01:00
Alexander Krotov f778957caf Improve documentation and comments 2019-11-16 13:53:47 +01:00
Alexander Krotov 47f8da6532 Expand tabs into spaces 2019-11-16 12:32:32 +01:00
Alexander Krotov 0b3f2a55df Do not use wildcard match in msgtype_has_file
This way there will be a compiler error notifying that the function needs to be updated when a new message type is added.
2019-11-16 12:31:13 +01:00
Nico de Haen 13ff2bd8c4 Fix wrong indents 2019-11-16 11:28:43 +01:00
Nico de Haen c690a64462 Update msg related location when message is deleted
resolves #843
2019-11-16 11:04:56 +01:00
B. Petersen d808bfe400 add some tests for me-chat and deaddrop 2019-11-13 22:31:18 +01:00
B. Petersen 1b30078c09 test archive functions 2019-11-13 10:16:57 +01:00
B. Petersen 0278875e03 add device-chat tests 2019-11-13 00:13:32 +01:00
B. Petersen d0ccf28678 do not add random label for unlabelled device-messages 2019-11-13 00:13:32 +01:00
B. Petersen 5023255ebc fix accidentally called maybe_add_bcc_self_device_msg() 2019-11-13 00:13:32 +01:00
B. Petersen a9fe77b62e use separate column for device-msg-labels 2019-11-12 16:10:48 +01:00
B. Petersen a42e197634 add device-message only once 2019-11-12 16:10:48 +01:00
B. Petersen fc32c85608 add device-msg 'consider enabling bcc_self' if bcc_self is disabled and an autocrypt-setup-message is received 2019-11-12 16:10:48 +01:00
B. Petersen dabd431b1f change default for bcc_self, preserve values for existing installations 2019-11-12 16:10:48 +01:00
B. Petersen 85b4817a1e restore some comments 2019-11-12 16:10:48 +01:00
B. Petersen 84c6113271 use enum for show_emails 2019-11-12 16:10:48 +01:00
B. Petersen 9506f8c38e use bool for exists_before_update 2019-11-12 16:10:48 +01:00
Alexander Krotov c6369b1c5a Implement TryFrom instead of TryInto
TryInto is derived automatically and its documentation recommends implementing TryFrom.
2019-11-10 15:38:58 +00:00
Alexander Krotov bfa0f9d911 Use the first subkey for encryption instead of the primary key 2019-11-10 16:32:09 +01:00
B. Petersen 37ecfa6b67 fix gm2local offset calculations 2019-11-09 20:26:00 +01:00
B. Petersen 99ba2fb358 let dc_timestamp_to_str() print the local time, not UTC times. the function is used for outputs directly shown to the user, eg. dc_get_msg_info() 2019-11-09 20:26:00 +01:00
B. Petersen 85ebde29dc do not resort chatlist on draft changes
resorting the chatlist on changing drafts has some ux issues.
eg. when the chatlist is visible together with the input field,
if may come to flickering resorting during input
or to a resorting just when the user leave the chat
as this might trigger set_draft().

but also on mobiles, the resorting is visible and a bit unexpected.
also it is unclear what happens when a chat with a draft is entered
and left without modifications.

the solution proposed here is to ignore draft on sorting
while still showing them in the chatlist
if they're newer as the last message.

a possible disadvantage is
that the date for the chat with a draft does not follow the ordering
(the ordering is by the last message),
however, the date is not shown as a "primary sort" criterion or so,
so it might be that this is completely okay.
also, of course, it affects only draft :)
2019-11-09 19:32:13 +01:00
B. Petersen 34f9961857 restore config-param if configure() fails 2019-11-06 22:59:14 +01:00
B. Petersen 5a11551b4d block sending to chats that do not support sending (normally, this should already be avoided in the ui) 2019-11-06 13:33:30 +01:00
B. Petersen 231110fb61 add profile-icon for device-chat 2019-11-06 13:33:30 +01:00
B. Petersen 4c30bf80ce target comments of @flub 2019-11-06 13:33:30 +01:00
B. Petersen f8afefa2c1 get contact- and chat-info for device-messages 2019-11-06 13:33:30 +01:00
B. Petersen b5d5d98645 implement add_device_msg() 2019-11-06 13:33:30 +01:00
B. Petersen 89f394ab86 create separate function for preparing a blob 2019-11-06 13:33:30 +01:00
B. Petersen cbaa4e03b3 basic devicetalk implementation 2019-11-06 13:33:30 +01:00
B. Petersen be08bcb22b rename DC_CONTACT_ID_DEVICE to DC_CONTACT_ID_INFO to be in-line with dc_msg_is_info() 2019-11-06 13:33:30 +01:00
holger krekel dcd92a894e fix export: write backup_time to the destination not the source sql file
and perform slightly cleaner teardown in python
2019-11-06 13:26:32 +01:00
holger krekel 6336eeb568 better error on has_backup() failing 2019-11-06 13:26:32 +01:00
holger krekel 6b18cbda1f refine dc_copy along the lines @flub did for blobstore 2019-11-06 13:26:32 +01:00
Alexander Krotov cf023ea557 sql: remove unnecessary ? in prepare() and prepare2() 2019-11-06 13:26:03 +01:00
Alexander Krotov 51a804a80f location: use "bool" for "independent" argument 2019-11-06 14:17:59 +03:00
B. Petersen 67e2e4d415 target comment of @hpk42 2019-11-04 13:20:35 +01:00
B. Petersen 8c2efa707a name special contact-ids where easily possible
the point of this pr is to get an overview
how and where DC_CONTACT_ID_DEVICE is used,
to prepare introducing a device-"chat".

i did not change the sql statements for now
as this would require some more refactoring
and has the potential to introduce bugs.
2019-11-04 13:20:35 +01:00
B. Petersen 87abc6e4a2 adapt wording 2019-11-03 21:36:40 +01:00
B. Petersen b9c7510b58 use boolean for jobs_needed 2019-11-03 21:36:40 +01:00
holger krekel 01e7caf65a use job_id as mail_id for SendableEmail -- it's only an internal id and job_id is unique enough. 2019-11-03 21:36:01 +01:00
holger krekel 1cfeb730c3 try to fix some smtp todos and do better error logging 2019-11-03 21:36:01 +01:00