Commit Graph

41 Commits

Author SHA1 Message Date
Nora Trapp
ac5aafaea9 Remove support for Xcode 12 2021-11-01 13:26:46 -07:00
Matthew Chen
a1ff722aad Fix race in notification cancellation. 2021-10-07 17:37:01 -03:00
Matthew Chen
c3802fc5ef Post notifications off the main thread in the NSE. 2021-10-05 16:24:31 -03:00
Matthew Chen
b2b3c312b6 Cancel notifications off the main thread. 2021-10-05 16:24:31 -03:00
Matthew Chen
aba599241c Improve handling of voip pushes on iOS 15. 2021-09-30 16:41:32 -03:00
Matthew Chen
e70302ac8f Refine NSE completion blocking, message processing. 2021-09-27 19:04:46 -03:00
Matthew Chen
c9cedeb8d6 Don't block on intent donation. 2021-09-16 15:47:49 -03:00
Matthew Chen
a82adcce60 Fix missing notifications with XCode 13 & iOS 14 and earlier. 2021-09-08 16:00:59 -03:00
Nora Trapp
0e3b1a196b Fix contentToUse mutability 2021-09-07 15:03:36 -07:00
Michelle Linington
7e6e99074e PR Feedback 2021-09-03 16:11:19 -07:00
Nora Trapp
2814ab7629 Convert to new Promise library 2021-09-03 11:41:34 -07:00
Matthew Chen
e1f35f89f0 Add more logging around missing notifications. 2021-09-03 13:52:47 -03:00
Matthew Chen
a3a43751ce Add more logging around missing notifications. 2021-09-03 13:47:49 -03:00
Matthew Chen
9703fb18ab Update l10n strings. 2021-09-02 22:52:36 -03:00
Matthew Chen
2b502ad609 Elaborate logging around missing notifications. 2021-09-02 22:51:26 -03:00
Eugene Bistolas
aa810205cf Defer NSE contentUpdating until donation completes, enable caching for avatars 2021-08-27 09:25:56 -10:00
Eugene Bistolas
de67f4cede Update NSE avatar size, add more logging 2021-08-26 09:47:12 -10:00
Eugene Bistolas
e166caa1de iOS 15 Notification Action Glyph Support 2021-08-18 08:29:53 -10:00
Eugene Bistolas
bd645b3048 iOS 15 communication notification support for calls 2021-08-17 13:19:14 -10:00
Eugene Bistolas
a4c3bb9c90 iOS 15 communication notification support for messages 2021-08-17 10:48:39 -10:00
Michelle Linington
aa25a1e274 Extend error messaging to beta users 2021-08-06 10:08:26 -07:00
Michelle Linington
8364e761a6 Add notification for reporting errors to internal users 2021-07-29 19:01:13 -07:00
Nora Trapp
de61926ec8 Make sure we wait to call the contentHandler until *after* we clear notifications 2021-07-02 16:38:13 -07:00
Nora Trapp
9584ed9495 Batch notification cancelation 2021-07-01 12:18:27 -07:00
Nora Trapp
1bac32f750 Don't keep notifications in memory 2021-07-01 12:18:27 -07:00
Matthew Chen
d0cbf8cfd0 Rework dependency access. 2021-03-25 09:24:27 -03:00
Michelle Linington
5341d59ba1 Lint 2021-02-12 14:03:16 -08:00
Michelle Linington
28be656568 PR Feedback 2021-02-12 13:14:13 -08:00
Michelle Linington
b4d36dcf31 Design changes for onboarding 2021-02-12 13:14:13 -08:00
Michelle Linington
eaef20b780 Alert user of safety number changes in group call
- Present SafetyNumberConfirmationSheet for all group members before
  joining call from lobby.
- Present SafetyNumberConfirmationSheet for newly joined participants
  with a safety number mismatch
- If the call is minimized or backgrounded, present a notification.
2020-12-08 12:59:56 -08:00
Matthew Chen
7c2180b666 Block message sends during blocking migrations phase. 2020-11-12 17:26:44 -03:00
Christopher Kobusch
4715240cc1 Added custom notification sounds
* user can add custom notification sounds from Files app (aiff, wav, or caf files)
* former OWSSound enum is now named OWSStandardSound, OWSSound turned into an alias for NSUInteger
* custom sounds get IDs based on the hash of the file name
2020-09-23 14:54:23 -07:00
Matthew Chen
ad6bda8a44 Rename singleton accessors. 2020-09-17 21:11:07 -03:00
Matthew Chen
916307d85b Tweak notifications for incoming reactions. 2020-08-25 17:47:33 -03:00
Matthew Chen
f13faeba7e Tweak notifications for incoming reactions. 2020-08-25 17:47:32 -03:00
Matthew Chen
1ba6d84003 React with thumbs up. 2020-08-05 14:28:14 -03:00
Nora Trapp
57a810658a Goodbye iOS 10 2020-05-27 17:34:32 -07:00
Nora Trapp
566e288421 Cancel stale reaction notifications when the reaction is removed or replaced 2020-04-20 10:25:31 -07:00
Nora Trapp
12f0be1a62 Receive support for delete for everyone 2020-04-13 12:49:27 -07:00
Michael Kirk
f198d9037d Merge tag '3.5.0.5' 2020-02-19 19:26:05 -07:00
Nora Trapp
88ac10de05 Notification Service Extension
The NSE should only run on iOS 13.3 or later where the "filtering" entitlement
is available since our notifications don't contain any content and will often
not trigger any user visible content. We control this by setting the deployment
target to iOS 13.3.

This does not handle calls as it's currently impossible to wake the main app or
launch CallKit from within the NSE. Should we reach a point where we need to use
this extension in production the service will need to be able to differentiate
between call and non-call messages and deliver them as VOIP or Vanilla pushes as
appropriate. Alternatively, Apple may introduce some way for us to signal the
main app that a call message has been received.

This does not currently address the potential for the NSE and the main app to be
running and trying to process messages at the same time. As long as the
websocket is connected and the main app is processing messages in a timely
fashion the NSE will never be called since the service will not send pushes for
these messages, but censorship circumvention users and users where the websocket
is disconnected for some reason will legitimately receive pushes and we will
want to process those messages. How we will handle these cases requires further
thought since just terminating the NSE when the app launches is not sufficient.
We could potentially do something like terminate the NSE everytime the main app
runs the message fetcher job which should only happen if either the user
pulls-to-refresh on the conversation list or the websocket is actively connected
and receiving messsages. I plan to address this in a follow-up pull request.

Currently this code will not ever be run since the service never sends vanilla
push notifications. Eventually we will need to add logic into the main app to:
a) detect we're on iOS 13.3 or later and b) update a flag on the service telling
it to stop using VOIP pushes for non-call messages. The API for requesting this
from the service does not yet exist.
2020-01-30 11:44:41 -08:00