Commit Graph

133 Commits

Author SHA1 Message Date
Jordan Rose
41b381b1b1 When starting a call, attemptRotationToDeviceOrientation()
Speculative fix for a hard-to-reproduce issue where the call view ends
up laid out in landscape and then clipped to portrait, rather than
being forced to portrait in the first place.

Possibly fallout from 856ced4062, which replaced an explicit call to
our UIDevice.ows_setOrientation(). We don't want to revert to that
because it messes up legitimate orientation detection.
2022-08-23 10:45:27 -07:00
george-signal
54fbe0b948
Don't show call window for already-terminated calls. 2022-08-12 13:04:38 -07:00
Jordan Rose
856ced4062 Use supportedInterfaceOrientations to force calls to portrait
Previously this used UIDevice.ows_setOrientation, an undocumented hack
to basically lie to the device about which way is up. This sounds
sketchy, but it's the result of a lot of testing various solutions for
something that could reliably force the app into portrait orientation.

However, every UIWindow has its own "supported orientations", provided
by the root view controller. And calls are implemented in their own
UIWindow (so that they don't disrupt whatever you were doing). So for
*calls specifically*, we can use supportedInterfaceOrientations to
force the app into portrait mode.

All other callers of UIDevice.ows_setOrientation work in the shared
main window, so they'll be left alone. This only changes things for
the call window.
2022-08-10 10:28:19 -07:00
Martin Böttcher
db44bb5017
Fix wrong localization key
Co-authored-by: Martin Böttcher <martin.boettcher@greenbytes.de>
2022-05-04 09:54:09 -05:00
Martin Böttcher
54b743de2d
moved older stringsdict changes into new branch; minor changes (#4205)
moved older stringsdict changes into new branch
2022-04-28 17:41:43 +02:00
Michelle Linington
d54d654cfc PR Feedback: Remove notImplemented altogether 2022-04-13 20:21:47 -07:00
Igor Solomennikov
4013006802 Use obscuresBackgroundDuringPresentation instead of dimsBackgroundDuringPresentation.
`UISearchController.dimsBackgroundDuringPresentation` is deprecated in iOS 12.
2022-04-12 13:24:57 -07:00
Dimitris Apostolou
62724cf0be Fix typos 2022-03-18 11:31:06 -07:00
Michelle Linington
7567dc146f Lint 2022-01-12 23:19:36 -08:00
Michelle Linington
76f13a4373 Fixes a bunch of unresolved symbol errors
Things succeed when building, but before and after Xcode is littered
with errors.
2022-01-12 23:19:36 -08:00
Matthew Chen
fc749b4d72 Change phone number. 2021-11-19 14:28:18 -03:00
Matthew Chen
3d7e8a0ba4 Add script to normalize includes and imports. 2021-10-21 09:21:12 -03:00
Matthew Chen
5d780d1589 Apply script to normalize includes and imports. 2021-10-21 09:21:10 -03:00
Matthew Chen
7d0485661d Move window manager to Signal target. 2021-10-19 17:59:13 -03:00
Nora Trapp
7ffcb089e4 Add haptic feedback to mention picker 2020-08-13 10:58:28 -03:00
Matthew Chen
a80eaf4ff2 Respond to CR. 2020-07-10 11:49:47 -03:00
Matthew Chen
1d2a1a2a26 Generate haptic feedback on main thread. 2020-07-10 11:29:16 -03:00
Nora Trapp
8a10d631f9 Add haptic feedback 2020-06-01 12:52:59 -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
Nora Trapp
31779b803e More specific reactions notifications 2020-01-27 11:59:30 -08:00
Matthew Chen
41f314ba1f Respond to CR. 2020-01-16 17:44:56 -03:00
Nora Trapp
61fe37de2b Hack around split view bug 2020-01-08 17:39:51 -08:00
Michael Kirk
f1dc3e564d expects to be called on main thread 2020-01-03 11:26:54 -07:00
Matthew Chen
ee819340c7 Always migrate to GRDB; show notification during background migrations. 2020-01-02 12:12:18 -08:00
Matthew Chen
c23ed76df0 Always migrate to GRDB; show notification during background migrations. 2020-01-02 12:12:18 -08:00
Michael Kirk
9d61e15685 Show info message context only when appropriate 2019-12-18 12:10:48 -08:00
Michael Kirk
997c93bc8e more logging around push registration failure checking 2019-12-13 07:55:33 -08:00
Nora Trapp
8d0a8ca3bd Notify for incoming reactions to your message 2019-12-03 15:26:01 -08:00
Nora Trapp
87ecf90bee Merge branch 'release/3.0.0' 2019-11-20 16:46:39 -08:00
Matthew Chen
35989761c2 Refine notifications.
Thanks to teor at The Tor Project.
2019-11-20 13:21:47 -03:00
Matthew Chen
e46eefe50e Remove readReturningResult(). 2019-11-14 10:39:33 -03:00
Nora Trapp
9148052cd6 Fix notification presentation over selected thread. 2019-10-21 10:49:19 -07:00
Michael Kirk
6fea78a6b3 Linking flow 2019-10-17 10:19:32 -06:00
Nora Trapp
90c562e94b Render conversation list + view in a side-by-side split on iPad 2019-10-08 20:10:01 -07:00
Michael Kirk
45c4066a80 Fix deadlock with thread.name
For contact threads, thread.name opened a sneaky transaction, which would
sometimes cause a deadlock.

This commit moves the name method to the contact manager and offers an explicit
transaction flavor. There is still a sneaky transaction flavor used in some
places where it's deemed dangerous to plumb through a transaction without
further scrutiny.
2019-08-23 18:45:23 -06:00
Michael Kirk
37468c4158 Fix missing: "you declined call" record for CallKit adapter
And fixes the corresponding debug assert that uncovered this bug.
2019-08-09 13:43:59 -06:00
Matthew Chen
bce0870d21 Fix rebase breakage. 2019-07-31 11:09:23 -03:00
Matthew Chen
1e363d2c65 Make uniqueId non-nil. 2019-07-31 10:50:59 -03:00
Michael Kirk
368dd7caf8 Merge tag '2.41.0.15' 2019-07-26 11:19:46 -06:00
Michael Kirk
ca554c4637 update notification copy 2019-07-24 11:22:19 -06:00
Matthew Chen
bdf5ca2645 Remove YDB connections. 2019-07-23 10:46:10 -03:00
Nora Trapp
3d1dd3dfe4 Remove rtlSafeAppend 2019-07-19 12:33:17 -07:00
Matthew Chen
ad49533e33 Make TSInteraction.thread non-nil. 2019-07-19 15:48:39 -03:00
Matthew Chen
8bd8cd89df Purify threads of YDB usage. 2019-07-16 13:50:49 -03:00
Matthew Chen
289b15f17f Convert threads to BaseModel. 2019-07-16 13:50:21 -03:00
Nora Trapp
c6688523c7 Address support for calling 2019-07-10 21:03:54 -07:00
Nora Trapp
c186755c66 Migrate IdentityManager and associated models to support UUIDs 2019-07-08 11:44:40 -07:00
Nora Trapp
a1f85fca30 Migrate profiles to support UUIDs 2019-07-02 11:19:50 -07:00
Michael Kirk
efafd6fb38 Create UUID message in DebugUI, rendering in homeview
ContactAvatarBuilder works with SignalServiceAddress

Currently this only functions with the GRDB adapter. There are other asserts
triggered in yap extensions.
2019-07-01 10:16:23 -06:00
Michael Kirk
0c944fe9f4 Incoming message has authorAddress 2019-06-27 14:22:13 -06:00