Commit graph

2794 commits

Author SHA1 Message Date
Scott Nonnenberg
fa00f08c95 MessageReceiver: Fix envelope id logging and make it consistent
FREEBIE
2017-08-07 16:14:49 -07:00
Scott Nonnenberg
82b2a611e3 MessageView: Always remove errors on re-render to prevent doubles
FREEBIE
2017-08-07 16:14:49 -07:00
Scott Nonnenberg
78c02f1154 Restore 'cancel' button on delete message confirmation dialog
FREEBIE
2017-08-07 16:14:49 -07:00
Scott Nonnenberg
559619eb49
Fix sync'd disappearing messages; prevent double-save
FREEBIE
2017-08-04 18:19:26 -07:00
Scott Nonnenberg
7e8f3ab5e7
Fix for "Can't find record for undefined.1"
Also, we didn't need to recalculate the number here anyway!

FREEBIE
2017-08-04 15:23:54 -07:00
Scott Nonnenberg
e223db56d9 Set messageKeysLimit to unlimited if communicating with our devices (#1348)
Set messageKeysLimit to unlimited if communicating with our devices

FREEBIE
2017-08-04 12:25:30 -07:00
Scott Nonnenberg
7e0bd82bd3 handleDataMessage: Remove if(confirm) checks, add try/catch
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
832b343031 Expiring messages: Add clarifying comment about destroy() ordering
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
7d4ae63501 MessageReceiver: Log empty event, flow promise properly
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
32e12f7d3c Conversation.notify(): introduce a promise to track completion
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
d3fb0e5b46 Expiring messages: destroy only after we've notified conversation
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
7faf83bc01 Read/Delivery Receipts: Wait for resolution in main queue
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
92ba295d52 Better logging for sync sent messages, and new (disappeared) msgs
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
ad8cb870d9 libtextsecure.js catch-up
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
ec70170829 ConversationView.unload: Add ability to provide reason for logging
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
c0f8812f9b ConversationView: when windows are closed, call unload()
Anyway, unload() is a more comprehensive method for doing what the close
handler was trying to do before.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
6f1a2a9b3e Conversation.markRead() - wait for all database saves are complete
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
0b4d14e5ac MessageReceiver: Ensure that we queue all cached first
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
b4f6721846 Fix manfest.css, libtextsecure.js catch-up
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
65283d2794 Unload conversations and old messages every half-hour
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
4ea457a01c Fix second fetchConversation call if unread > 0
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
73a77c7b97 Consistent returns, no more eventTarget, comments for tricky bits
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
8c231d9830 MessageReceiver: Flow promises back properly in decrypt error case
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
31d7e652fe Dismiss the app loading screen if we failed to connect to socket
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
af2ce56c8d Reset MessageReciever queue whenever possible
(like we do with the conversation queue already)

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
305bd6b3b8 App loading screen: show messages processed so far
Also, show the same loading screen on index.js before we've bootstrapped
the app.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
e36aa524c9 background.js: Flow promises properly in error case
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
39795170c1 Handle the 'extension loaded, reopen window' scenario
Not sure exactly how to think about Chrome app lifetimes, so we're
being conservative. We only show the full-application loading screen
once, on first display of the inbox.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
53f2bfbb57 Animated loading screens on startup and first conversation load
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
3e8b34f3d0 findOrCreateById instead of private-specific method
Anyway, findOrCreateById with no type didn't succeed, because the
conversation didn't validate.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
ef3431af1b isUntrusted: Return false if firstUse is true
Because users will see this upon first trying to communicate with a new
contact if they're quick about it.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
f38d715250 Read receipts: Log sender and timestamp when related msg not found
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
c6bc167975 Increase log length to 5000, since we're logging so much now
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
82c0b4aaa6 Add return to onContractReceived for consistency
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
9dc406dc8d Apply reliable trigger to Backbone.Collection as well
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
3e0fa995dd When finding all groups involving a number, load from DB not memory
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
0adc398a6f Fetch conversation before saving in all sync handlers
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
9db0a58260 Whenever adding something to a queue, include a timeout
No more wedged queues!

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
cc2c3edaa6 Override Backbone's trigger with one that catches exceptions
Model operations are vulnerable to exceptions thrown by event handlers.
Because this can interrupt really important data operations, it's better
to let the operation continue and log the error. In all likelihood it's
a view-related problem, and that shouldn't cause any data operation to
fail.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
700272cf85 Add a pure copy from backbone into reliable_trigger.js for diff
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
7b55fde92d Gruntfile: Remove firefox target in sauce labs task
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
b985228160 Last seen indicator/scroll down button - defensive removal
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
4f90cefd4f More bullet-proofing - reject surrounding promise if save() fails
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
1eb450ca35 Conversation: Start w/DEFAULT verified state, avoid null timestamp
Fix too-aggressive verification notifications on startup by starting a
conversation with the right initial verified state, and then making sure
to fetch() before setting a new verified state.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
bd0050b6c6 Cache messages on receipt, remove from cache when processed
FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
e6859a3684 Ensure that promises always resolve, or that rejections are okay 2017-08-04 12:03:25 -07:00
Scott Nonnenberg
4da1722ee8 Bullet-proof _setVerified and handleDataMessage against rejections
And the weird behavior we get from $.Deferred.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
5da324103a Throttle calls to getProfile when opening conversation
We don't want to throttle other calls to getProfile, so we localize this
to the fetch we do when we first open a conversation.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
aa80cdd74d ConfirmationDialogView: Make showCancel an explicit option
Also, don't call resolve/reject callbacks if they weren't provided.

FREEBIE
2017-08-04 12:03:25 -07:00
Scott Nonnenberg
14765599f3 Delete individual message
FREEBIE
2017-08-04 12:03:25 -07:00