Commit Graph

353 Commits (49839900bcfd582e27e4e271aef3a4b57f056dc8)

Author SHA1 Message Date
Matthew Chen 5b50e81b4f Rename fail macros in Swift. 7 years ago
Matthew Chen cf6f3841a8 Apply new Swift logging. 7 years ago
Michael Kirk 7e8b2e3034 Faster conversation presentation.
There are multiple places in the codebase we present a conversation.

We used to have some very conservative machinery around how this was done, for
fear of failing to present the call view controller, which would have left a
hidden call in the background. We've since addressed that concern more
thoroughly via the separate calling UIWindow.

As such, the remaining presentation machinery is overly complex and inflexible
for what we need.

Sometimes we want to animate-push the conversation. (tap on home, tap on "send message" in contact card/group members)
Sometimes we want to dismiss a modal, to reveal the conversation behind it (contact picker, group creation)
Sometimes we want to present the conversation with no animation (becoming active from a notification)

We also want to ensure that we're never pushing more than one conversation view
controller, which was previously a problem since we were "pushing" a newly
constructed VC in response to these myriad actions. It turned out there were
certain code paths that caused multiple actions to be fired in rapid succession
which pushed multiple ConversationVC's.

The built-in method: `setViewControllers:animated` easily ensures we only have
one ConversationVC on the stack, while being composable enough to faciliate the
various more efficient animations we desire.

The only thing lost with the complex methods is that the naive
`presentViewController:` can fail, e.g. if another view is already presented.
E.g. if an alert appears *just* before the user taps compose, the contact
picker will fail to present.

Since we no longer depend on this for presenting the CallViewController, this
isn't catostrophic, and in fact, arguable preferable, since we want the user to
read and dismiss any alert explicitly.

// FREEBIE
7 years ago
Michael Kirk 82e559d11b Use swift macros for main thread assert 7 years ago
Michael Kirk c05700fd98 Log in OWSFail
step 1: rename OWSFail->OWSFailNoProdLog
step 2: rename OWSProdLogAndFail->OWSFail
step 3: Convert OWSFailNoProdLog->OWSFail where we want logging
step 4: Rename OWSCFail->OWSCFailNoProdLog
step 5: Rename OWSProdLogAndCFail -> OWSCFail
step 6: Convert OWSCFailNoProdLog -> OWSCFail where we want logging
7 years ago
Matthew Chen d6cb07cc4a Respond to CR. 7 years ago
Matthew Chen 27b6a5e5bb Open message search results. 7 years ago
Matthew Chen 3964b78ff7 Reduce usage of JSQ. 8 years ago
Matthew Chen 4d8c764789 Migrate to Swift 4. 8 years ago
Matthew Chen 77b72b6b06 Migrate to Swift 4. 8 years ago
Matthew Chen 916d55c55d Migrate to Swift 4. 8 years ago
Matthew Chen 28f7142a59 Auto-migration to Swift 4. 8 years ago
Michael Kirk 29d08545e2 Use OWSNavigationController instead of UINavigationController
- [ ] document picker
- [ ] camera picker
- [ ] image picker
- [ ] restore "confirm to go back" behavior (interactive pop gesture?)

// FREEBIE
8 years ago
Matthew Chen 9936003637 Respond to CR. 8 years ago
Matthew Chen 9a4889c4fb Simplify debug notifications. 8 years ago
Matthew Chen 4a4882ebe5 Add debug notification. 8 years ago
Matthew Chen 91d54360ba Add contact view. 8 years ago
Matthew Chen c5981b164b Notify users of corrupt messages. 8 years ago
Matthew Chen 21ab670fc9 Clean up ahead of PR. 8 years ago
Michael Kirk 9c81eb44a1 Replace remaining UI usage of `interaction.description`
// FREEBIE
8 years ago
Matthew Chen 6caa5b87b6 Add more asserts around thread in SAE. 8 years ago
Michael Kirk 3cb53f5f44 Respect system alert volume for notifications while in app
// FREEBIE
8 years ago
Michael Kirk 319e0d808f Merge tag '2.21.0.14' into release/2.22.0 8 years ago
Michael Kirk 3aebaefc31 A lighter touch for the fix-call connect.
Though it should be fine, reloading the callUIAdapter is a bit heavy
handed. And the current implementation is prone to being broken, since
we sometimes forget not to treat callUIAdapter as a singleton.

Longer term we can find a way to either: make callUIAdapter a true
singleton or possibly make callUIAdapter a private member of something
which *is* a true singleton.

Since we only *need* it to be reloaded the one time the migration runs
(or when a user changes settings which should be rare) it makes sense to
remove it from the happy path.

// FREEBIE
8 years ago
Michael Kirk a1de99f1f1 Merge tag '2.21.0.9' 8 years ago
Matthew Chen d6f4db1523 Rename TSStorageManager to OWSPrimaryStorage. 8 years ago
Michael Kirk d3be2b4a3b Vibrate when playing sound as alert
// FREEBIE
8 years ago
Michael Kirk 6077367e66 Notification sounds should respect silent switch
// FREEBIE
8 years ago
Michael Kirk a068b85734 Audio splashscreen artwork/copy
copy tweaks

// FREEBIE
8 years ago
Matthew Chen a71e00397f Fix build break related to Swift 4.1 syntax. 8 years ago
Michael Kirk cf6dfe08bb Custom audio notifications upgrade experience
TODO: update art
8 years ago
Michael Kirk 5959cdf070 Simplify call privacy settings
We've long allowed users to configure what shows up in message
notifications:

- name: content (by default)
- just name (no content)
- generic notification (no name nor content)

Now we're dual purposing that setting to apply to calls. If someone
doesn't want to show names in the message notifications, presumably also
don't want that name showing up in the call log.

Also, since the earlier CallKit/iCloud issues had been addressed before
iOS11, we upgrade all iOS11 users to the more intuitive CallKit
interface.

Also: introduce "use system call logs" toggle when available. It will be
enabled by default, but we disable it for legacy users who'd explicitly
opted *out* of CallKit.

// FREEBIE
8 years ago
Matthew Chen 32b87d0e58 Remove custom ringtones. 8 years ago
Matthew Chen e54cf313e8 Use quiet versions of the notification sounds in foreground. 8 years ago
Matthew Chen a0f4723fa2 Update call sounds. 8 years ago
Matthew Chen a44a117612 Add custom ringtone sounds. 8 years ago
Matthew Chen dc8b8ca0bd Add per-thread custom notification sounds. 8 years ago
Matthew Chen 9aa02489b8 Custom notification sounds in local notifications. 8 years ago
Matthew Chen 5c3f6b0ee5 Custom notification sounds. 8 years ago
Matthew Chen d648a258d1 Merge branch 'hotfix/2.19.7' 8 years ago
Matthew Chen abfd333a17 Address Indic script crash. 8 years ago
Michael Kirk cb8767d19e CR: duplicate comments, DRY
// FREEBIE
8 years ago
Michael Kirk debd556e09 Fix notification % escaping, debug UI
Consolidated the notifications debug UI (and fixed it) to make testing
this a bit easier.

// FREEBIE
8 years ago
Matthew Chen bbd689bfd0 Add protocol context to protocol kit. 8 years ago
Matthew Chen d3e16583eb Add protocol context to protocol kit. 8 years ago
Matthew Chen 9258b0883e Clean up TSStorageManager usage. 8 years ago
Matthew Chen 85686d3144 Continue TSStorageManager refactor. 8 years ago
Matthew Chen 9a990b58e8 Respond to CR. 8 years ago
Matthew Chen a29c4ce5d6 Pull out OWSStorage base class for TSStorageManager. 8 years ago
Matthew Chen 7a1e47cd26 Add asserts around Swift singletons. 8 years ago
Matthew Chen 69e0bcd308 Fix tests. 8 years ago
Matthew Chen 9da165b846 Continue conversion of app setup. 8 years ago
Matthew Chen 2eba371656 Clean up ahead of PR. 8 years ago
Matthew Chen b4e8df79da Migrate environment to SignalMessaging. 8 years ago
Matthew Chen c817aa51b3 Migrate environment to SignalMessaging. 8 years ago
Michael Kirk fcb17585b0 fix compiler warnings
// FREEBIE
8 years ago
Matthew Chen bf21d0c0ed Enable logging in SAE; rework log file management to include multiple log directories. 8 years ago
Matthew Chen 8cc33b3de1 Refine loading view of share extension. 8 years ago
Matthew Chen e7b32899cb Sketch out SAE load screen; make a number of infrastructure changes. 8 years ago
Matthew Chen 7429e1968c Clean up ahead of PR. 8 years ago
Matthew Chen edaf65223a Migrate to shared data NSUserDefaults. 8 years ago
Michael Kirk a11d83187b WIP: Framework-friendly - compiles but crashes on launch
// FREEBIE
8 years ago
Michael Kirk 607a5cb08e Fix typo in re-registration flow
// FREEBIE
8 years ago
Michael Kirk e84fcd7c94 Registration bug also affects other versions of iOS
// FREEBIE
8 years ago
Matthew Chen 00feb14b10 Respond to CR.
// FREEBIE
8 years ago
Matthew Chen 6e840ff956 Fix build warnings from XCode 9. 8 years ago
Michael Kirk c0bcc40a6f Ensure we re-upload push tokens after re-registering.
// FREEBIE
8 years ago
Matthew Chen 03241128f6 Respond to CR.
// FREEBIE
8 years ago
Michael Kirk c5244e175e orphan cleanup shouldn't happen until DB is registered
// FREEBIE
8 years ago
Matthew Chen 3b945a9da2 Respond to CR.
// FREEBIE
8 years ago
Matthew Chen 227fd5280d Resize conversation view cells as necessary.
// FREEBIE
8 years ago
Michael Kirk 3080cb512b Compose View: collation index and group search
- Include table index for contacts
- Fix extra spacing in OWS table view
- Separate search results into contact/invite sections
- Include groups in search results when composing new message
- Compose Screen search matches on group member names

// FREEBIE
8 years ago
Michael Kirk 9a7e3cb9d8 Register for manual message fetching when unable to obtain push tokens
// FREEBIE
8 years ago
Michael Kirk df15c904bc Rework push registration
== Account Registration ==

Not complete until push tokens are uploaded

== Remote Notifications Registration ==

Extracted from PushManager

- wait for notification-settings registration to complete before
  requesting push tokens, otherwise it's possible token requests will
  be ignored.

- Less state required for push notification callbacks, specifically, we
  no longer need to ensure we've created a promise before the
  registration delegate methods get called.

- no more TOCFuture in Signal-iOS (still in SSK for now). It's not in
  cases of inexplicable behavior - one a recently, push notification
  premature free, in redphone, and more popular use, and I've seen two
  futures inexplicably being nil.  Instead, let's consolidate around
  PromiseKit for popularly used, maintained, strongly-typed futures.

- separate logic for registering for vanilla push/voip notifications
  (few dependencies) from responding to UILocalNotifications (lots of
  dependencies). Ultimately I'd like to consolidate the remaining
  UILocalNotifications logic with the existing NotificationsManager

== Misc ==

more debug logging
more uniform logging
remove stale logic around newly registered user

// FREEBIE
8 years ago
Michael Kirk 876521f4c3 Fetch messages sooner when launched from background
The only reason a notification wakes/launches the app is to fetch
messages.

However, upon launching, especially if the app had been killed, it can
take a second or two before being notified of the notification that woke
us. Rather than wait, just fetch messages ASAP.

// FREEBIE
8 years ago
Matthew Chen e0194fd605 Allow multiple simultaneous GIF downloads.
// FREEBIE
8 years ago
Michael Kirk 175474e0d1 Read receipt update screen
// FREEBIE
8 years ago
Michael Kirk a2421d5b3e Fix "unknown attachment" notifications
The transaction in which the attachments were created hasn't been
committed yet.

// FREEBIE
8 years ago
Michael Kirk 344903fa5b Show proper thread from notification
// FREEBIE
8 years ago
Matthew Chen 9573e0e16d Move more work off the main thread.
// FREEBIE
8 years ago
Matthew Chen 11cadf4200 Send, receive & show read receipts to senders/from receivers.
* Send read receipts to senders.
* Honor "send read receipts" preference.
* Process read receipts from recipients.
* Refactor "mark as read" logic.
* Serialize and apply recipient read receipts received before sync transcript.
* Show recipient read receipts in conversation view.

// FREEBIE
8 years ago
Matthew Chen bfb03c0db4 Fix message processing edge cases.
// FREEBIE
8 years ago
Matthew Chen 8a4d67a6e4 Respond to CR.
// FREEBIE
8 years ago
Matthew Chen 183f0f1ccd Respond to CR.
// FREEBIE
8 years ago
Matthew Chen 40d728e022 Add read receipts preference.
// FREEBIE
8 years ago
Matthew Chen 80e5f281c6 Rename app preferences class.
// FREEBIE
8 years ago
Matthew Chen 2c68b06412 Respond to CR.
// FREEBIE
8 years ago
Matthew Chen 04d452b074 Normalize conversation presentation logic.
// FREEBIE
8 years ago
Matthew Chen b6d782046a Normalize conversation presentation logic.
// FREEBIE
8 years ago
Matthew Chen c106794fe8 Rename conversation view.
// FREEBIE
8 years ago
Matthew Chen 928525c31e Rename home view.
// FREEBIE
8 years ago
Michael Kirk 59eb782d57 Optimize layout for profile upgrade, remove other upgrade screens
// FREEBIE
8 years ago
Michael Kirk 0244a82031 code cleanup for clarity
// FREEBIE
8 years ago
Michael Kirk 73a441a28c introducing profiles
// FREEBIE
8 years ago
Matthew Chen a825fad47b Start reworking the contact offers.
// FREEBIE
8 years ago
Michael Kirk 2e83643327 Don't consider registration complete until user registers their push
notification tokens.

// FREEBIE
8 years ago
Michael Kirk ed4de7e8af Simplify code / pre-cache localNumber
Now that localNumber is read from a dedicated dbConnection we don't have
to worry about it blocking.

// FREEBIE
8 years ago
Matthew Chen 03774216a0 Respond to CR.
// FREEBIE
8 years ago
Matthew Chen 6ac4d8e971 Delete profile avatars on disk when unregistering.
// FREEBIE
8 years ago
Matthew Chen bca736a2b7 Merge tag '2.13.4.0'
// FREEBIE
8 years ago