Commit Graph

1330 Commits

Author SHA1 Message Date
Michael Kirk
006021ea41 Fix: group color change doesn't immediately apply
Because we were fetching a new thread instance, instead of updating the
existing thread instance, classes which were bound to the old thread instance
weren't updating. This affected the HeaderView.AvatarView.thread and the
ConversationStyle.thread.
2018-10-01 17:06:09 -06:00
Matthew Chen
ebae75af00 Revert 'new sort id'. 2018-09-27 19:40:51 -04:00
Matthew Chen
3c22d0b0c8 Swift exit(). 2018-09-27 16:56:54 -04:00
Michael Kirk
e3e6c31612 fix hang on conversation load 2018-09-27 15:29:00 -04:00
Michael Kirk
79add78d51 Merge branch 'release/2.30.1' 2018-09-27 13:03:35 -06:00
Matthew Chen
bb5c9ff106 Respond to CR. 2018-09-27 13:56:07 -04:00
Matthew Chen
c0f4254599 Mark CDS feature flag for removal. 2018-09-27 13:56:07 -04:00
Matthew Chen
0884598a3a Fix CDS cookie handling. 2018-09-27 13:56:07 -04:00
Matthew Chen
c368aabf9c Fix the "de-register" logic. 2018-09-27 13:56:07 -04:00
Matthew Chen
b10bf441c4 Add note about curl cookie support. 2018-09-27 13:56:07 -04:00
Matthew Chen
370c96af53 Enable CDS in contact intersection. 2018-09-27 13:56:07 -04:00
Matthew Chen
43d0b9b9bf Fix misnamed method. 2018-09-27 13:56:07 -04:00
Matthew Chen
b6a14ea014 Fix the CDS version checking. 2018-09-27 13:56:07 -04:00
Matthew Chen
bcb882f5aa Update CDS URLs. 2018-09-27 13:56:07 -04:00
Matthew Chen
b3ad6e27dc Rework conversation message bubble colors; add "conversation colors" class. 2018-09-27 09:07:47 -04:00
Matthew Chen
8db4595bdc Rework group avatars to reflect conversation colors. 2018-09-27 08:55:20 -04:00
Michael Kirk
fe7d69e9c6 Update thread's sorting order based on whatever the currently last message is 2018-09-26 09:52:34 -06:00
Michael Kirk
02692e42bd remove addressed TODO's 2018-09-26 09:52:34 -06:00
Michael Kirk
3240e0d9d0 Be explicit about receivedAt time
We were often using `timestampForLegacySorting`, which is convoluted for when
we actually just want received time.

In some sense this is a superficial change, but it's part of auditing that
we've completed moved away from timestampForLegacySorting.
2018-09-26 09:52:34 -06:00
Michael Kirk
6bfd0f29ed mark self-sent messages as read as soon as it was created 2018-09-26 09:52:34 -06:00
Michael Kirk
c0c973de1c Sort gallery finder by sortId 2018-09-26 09:52:34 -06:00
Michael Kirk
b281b37637 replace thread.lastMessageDate/archivalDate -> thread.lastSortId, thread.archivedAsOfSortId
Update migration accordingly

Date shown on home view cell is message.receivedAt
2018-09-26 09:52:34 -06:00
Michael Kirk
90aa593dcd sortId vs. Read status 2018-09-26 09:52:33 -06:00
Michael Kirk
089c4f09ea bump all views which rely on message sorting 2018-09-26 09:52:33 -06:00
Michael Kirk
ab55e85304 step 1: timestampForSorting audit, change signature
No change in functionality in this commit, I just broke the signature to have a
systematic audit of the callsites. Added TODO's with the plan for each call.
2018-09-26 09:52:33 -06:00
Michael Kirk
e1a46d85fb investigation shows we don't use this timestamp for call error messages 2018-09-26 09:52:33 -06:00
Michael Kirk
df61316495 minimize diff senderTimestamp -> timestamp 2018-09-26 09:52:33 -06:00
Michael Kirk
00d0d1e002 Remove legacy Error backdating - no changes in functionality
Historically we would backdate the SN change messages, but since adopting
non-blocking SN changes long ago, they're already sorted properly by creation
time, so backdating has been unnecessary for a while.

I also audited that all other error messages are saved directly after creation.

I applied deprecation attributes as appropriate as I audited.
2018-09-26 09:52:33 -06:00
Michael Kirk
550e7ba63b Create disappearing message update info messages before messages they affect
Since we're no longer sorting by timestamp we have to ensure we save the update
info message before we save any affected message, e.g. in the case of implicit
updates.
2018-09-26 09:52:33 -06:00
Michael Kirk
eef1368ad3 Timestamp audit step1: change signature
There is no change in functionality in this commit.

Apart from clarifying what the timestamp means (it's the timestamp of the
*sender*), this intentionally breaks all the call sites, so I could have a sane
way to thoroughly audit wherever we're passing in timestamps, to see where
we're depending on them to affect sort order.

For the sake of a cleaner diff of meaningful changes, instead of "fixing"
everything in this commit, I've just added comments and renamed signatures.
2018-09-26 09:52:33 -06:00
Michael Kirk
a60d8eb161 WIP: migration / autoincrement logic
TODO:

-[ ] contact offer
-[ ] verify all paths that utilized timestampForSorting, e.g. make sure SN appear before the message they affect, etc.
-[x] Monotonic ID
-[x] New extension which sorts by id
-[x] Migration
  -[ ] batch migration?
2018-09-26 09:52:33 -06:00
Matthew Chen
72562920ed Fix author conversation colors. 2018-09-26 09:19:12 -04:00
Michael Kirk
bccb633b6c fix release compile 2018-09-25 17:16:12 -06:00
Matthew Chen
8910f1f65a Enable conversation colors. 2018-09-25 16:11:37 -04:00
Matthew Chen
98630cca50 Respond to CR; add db utility methods to test base classes. 2018-09-21 09:21:34 -04:00
Matthew Chen
559c496ae5 Clean up. 2018-09-21 09:08:39 -04:00
Matthew Chen
66fc389fba Get SSK tests building and running. 2018-09-21 09:08:39 -04:00
Matthew Chen
87836f506b Move more singletons to SSKEnvironment. 2018-09-21 09:06:48 -04:00
Matthew Chen
39ebdf0921 Log curl command for failed requests in debug builds. 2018-09-20 14:02:35 -04:00
Matthew Chen
15b52db8bf Respond to CR. 2018-09-20 08:55:19 -04:00
Matthew Chen
29bb69032a DRY up the debounce of db extension version increment. 2018-09-20 08:55:19 -04:00
Matthew Chen
e8186a7005 Fix rebase breakage. Make environment properties mutable in tests. 2018-09-19 16:30:03 -04:00
Matthew Chen
3b2c5bfc7b Modify mock environments to register all db views. 2018-09-19 16:29:15 -04:00
Matthew Chen
83e6484156 Respond to CR. Rework how OWSUploadOperation's networkManager property. 2018-09-19 16:28:03 -04:00
Matthew Chen
edcedd2845 Remove selfRecipient method. 2018-09-19 15:11:26 -04:00
Matthew Chen
e1db60c1c0 Rework creation of singletons. 2018-09-19 15:11:26 -04:00
Matthew Chen
4ad7ca79b7 Respond to CR. 2018-09-18 16:44:33 -04:00
Matthew Chen
e8eac9f30b Clean up ahead of PR. 2018-09-18 16:35:13 -04:00
Matthew Chen
b883209f91 Refine logging. 2018-09-18 16:35:12 -04:00
Matthew Chen
69290f7ec8 Improve logging around failied keychain deletion. 2018-09-18 09:07:54 -04:00