Commit Graph

398 Commits

Author SHA1 Message Date
Nora Trapp
8c633c718e Private Story -> Custom Story 2022-10-18 15:41:04 -07:00
Nora Trapp
5be184dc21 Add the ability to view all your signal connections 2022-10-18 13:39:00 -07:00
Nora Trapp
88eafd3458 Don't allow creating a group story for a group we can't message in 2022-10-18 11:09:10 -07:00
Nora Trapp
5f048550e1 Add always dark support to blocking announcement only view 2022-10-18 11:09:10 -07:00
Nora Trapp
d5f4c92018 Update new story button 2022-10-17 23:45:00 -07:00
Nora Trapp
2c59b2f7b3 Fix localization in safety number sheet 2022-10-17 23:43:56 -07:00
Harry
150fb036cb
Fix scaleAspectFill 2: electric boogaloo 2022-10-14 18:11:13 -07:00
Harry Sanabria
da147d9676 Fix MediaMessageView scale fill constraints for portrait images with smaller aspect ratios 2022-10-14 10:09:39 -07:00
Evan Hahn
370ff654e7
Change license to AGPL
Change license to AGPL

This commit:

- Updates the `LICENSE` file

- Start every file with something like:

      // Copyright YEAR_FIRST_PUBLISHED Signal Messenger, LLC
      // SPDX-License-Identifier: AGPL-3.0-only

---

First, I removed existing license headers with this Ruby 3.1.2 script:

    require 'set'

    EXTENSIONS_TO_CHECK = Set['.h', '.hpp', '.cpp', '.m', '.mm', '.pch', '.swift']

    same = 0
    different = 0

    all_files = `git ls-files`.lines.map { |line| line.strip }
    all_files.each do |relative_path|
      if relative_path == 'Pods'
        next
      end

      unless EXTENSIONS_TO_CHECK.include? File.extname(relative_path)
        next
      end

      path = File.expand_path(relative_path)

      contents = File.read(path)
      new_contents = contents.sub(/\/\/\n\/\/  Copyright .*\n\/\/\n\n/, '')

      if contents == new_contents
        same += 1
      else
        different += 1
      end

      File.write(path, new_contents)
    end

    puts "updated #{different} file(s), left #{same} untouched"

I'm sure this script could be improved, but it worked well enough.

Then, I created `Scripts/lint/lint-license-headers` and ran it to auto-
fix a lot of files. This changed the mode of some files, but I think
that's actually desirable. For example,
`SignalServiceKit/src/Util/AppContext.m` previously had a mode of
`0755/-rwxr-xr-x`, and it's now `0644/-rw-r--r--`.

Then I fixed some stragglers and updated the precommit script.

See [a similar change in the Desktop app][0].

[0]: 8bfaf598af
2022-10-13 08:25:37 -05:00
Harry
9d4fb97dfd
Add story media previews to conversation picker in story send flow
* Support scale aspect fill in MediaMessageView

* show image/video previews on conversation picker when in stories only send flow

* show text story previews in conversation picker

* fix media preview border color

* update rotation for RTL

* PR feedback
2022-10-12 09:59:49 -07:00
Harry
e4316d3a39
A bunch of story fixes
* Hide story video duration tooltip when changing selection

* update story row swipe action title font

* Update tab bar icons

* Fix ghost safe area shown when cancelling an interactive dismiss of a chat view

* Use forced dark theme background color for cell selection in story info sheet

* Exclude hidden story contexts from conversation picker

* remove unused asset

* pr feedback
2022-10-12 09:54:50 -07:00
Max Radermacher
3ffa2dca2c
Fix nullability for countryNameFromCountryCode 2022-10-11 17:30:58 -07:00
Harry
3f0fe34089
Disable view once media in stories send flow
* Disable view once media in stories send flow

* Remove stories from picker if sending a view once media

* dont show view once button if sending to stories from sharesheet
2022-10-11 13:11:48 -07:00
Max Radermacher
ef91c13909 Remove unused RecipientPickerDelegate method
It appears unused since 8e4fd443cc.
2022-10-11 10:13:56 -07:00
Max Radermacher
db2677b0a7 Fix typo in shouldUseAsyncSelection 2022-10-11 10:13:56 -07:00
Evan Hahn
3318cbbb86
Add method to add multiple table sections at once
This should have no user impact.

I think this change is useful on its own, but may also make an upcoming
change easier.
2022-10-11 09:11:25 -07:00
Evan Hahn
2084c90715 Fix genstrings warning for stories string
Quiets this warning:

> genstrings: warning: Key "STORY_SETTINGS_WHO_CAN_VIEW_THIS_FOOTER"
> used with multiple comments "Section footer for the 'viewers' section
> on the 'story settings' view" & "Section footer for the 'viewers'
> section on the 'story settings' view."

Also changes another string for consistency (removes the trailing
period).
2022-10-07 17:10:53 -05:00
Evan Hahn
1b00741b6d
Fix remaining SwiftLint failures, lint more strictly
This fixes our remaining SwiftLint violations, which were small.

It also updates the precommit script to fail if any violations are
found, even warnings. This will cause CI to fail if you include a file
that isn't SwiftLint-compatible.
2022-10-07 12:00:26 -05:00
Max Radermacher
61fd33fa07 Remove redundant property assignments 2022-10-06 17:10:46 -07:00
Nora Trapp
3e9f51e512
Fix some stories strings 2022-10-06 13:06:48 -07:00
Harry
88ed7a0376
Fix group call member sheet header blur effect
* Fix group call member sheet header blur effect

* pr feedback
2022-10-05 12:23:43 -07:00
Harry
29fbb192d5
Add my story privacy settings learn more
* Add my story privacy settings learn more

* light fixes for boost sheet

* PR feedback

* audit usages of InteractiveSheetViewController
2022-10-04 15:11:16 -07:00
Nora Trapp
b9842b5eb2 Allow forwarding to stories 2022-10-03 21:35:32 -07:00
Nora Trapp
ba90b3989d Fix the number of stories rendered on conversation picker 2022-10-03 21:35:32 -07:00
Nora Trapp
8f8ec0c249 Show red X when picking contacts to exclude 2022-10-03 21:35:32 -07:00
Nora Trapp
1b243581db Update '+ New Story' Button 2022-10-03 21:35:32 -07:00
Harry
74228f424e
Add StoryContextAssociatedData to compute story tab badge count without hidden stories
* Add StoryContextAssociatedData and db migrations

* Remove hideStory from ThreadAssociatedData

* Remove lastViewedStoryTimestamp and lastReceivedStoryTimestamp from TSThread

* drop deprecated columns in db migration

* add indexes

* dump schema.sql

* Update unviewed stories SQL query

* fix thread fetching for incoming story messages

* reload story tab badge when StoryContextAssociatedData changes

* Add test for TSGroupModel backwards-compatible deserialization

* move db migration

* Only use StoryContextAssociatedData for story badge count

* update StoryContextAssociatedData lastReceivedTime when a story message is deleted

* catch group threads for outgoing story messages too

* clean up sql query

* Only update lastReceievedStoryTimestamp for remote deletions

* add latestUnexpiredTimestamp to StoryContextAssociatedData
2022-10-03 21:16:01 -07:00
Nora Trapp
6930ffe2fa Remove old group capabilities 2022-09-29 09:35:00 -07:00
Harry
da06c1357c
Show my story privacy settings the first time you send to my story
* Add first send story privacy field to AccountRecord proto

* Store hasSetMyStoriesPrivacyKey on StoryManager

* sync hasSetMyStoriesPrivacy state

* Reuse MyStorySettingsViewController in a sheet view controller

* Show my story privacy settings from conversation picker if unset when selecting my story destination

* reload my story row to change subtitle

* pr feedback
2022-09-27 10:06:01 -07:00
Harry
c544e46ee1
Story fix bargain bin
* fix conflict between story viewer context menu drag and navigational pan gestures

* Fix RTL chevrons on story list

* swipe only between hidden stories OR visible stories, never both

* Add table row swipe actions for hiding/unhiding stories & update icons to sharp corners instead of rounded

* make story viewer context menu always dark theme to match design mocks

* dont fail dev builds when harmlessly double dismissing a context menu, which happens if backgrounding the app while the context menu is open

* update my story row icons to 16pt

* swipe to delete on my story rows

* Use themed icons. Get filled versions of various context menu icons from design
2022-09-26 17:10:10 -07:00
Harry
f65493ae7c
Fix InteractiveBottomSheetController on old devices/iOS versions
* fix InteractiveBottomSheet controller

* Remove outside styled bottom sheet handle as per design request

* allow shrinking the bottom sheet after maximizing, as per design request

* tweak animation values per design request

* nits
2022-09-26 12:20:51 -07:00
Nora Trapp
96d8abac67 PR Feedback 2022-09-22 14:53:29 -07:00
Nora Trapp
c8dc629351 Show active group stories in the conversation picker 2022-09-22 14:53:29 -07:00
Igor Solomennikov
094fa0f30d
Allow attaching links to text stories with "Generate Link Previews" setting being OFF. 2022-09-21 14:55:49 -07:00
Harry
1710bf98d1
Fix iOS 16 UITextView sizing issue in OWSTableViewController2
* Fix iOS 16 UITextView sizing issue in OWSTableViewController2

* remove iOS 16 check, add iOS 17 canary check
2022-09-21 13:28:11 -07:00
Evan Hahn
02494b048a
Hide left groups from various pickers
If you've left a group, we shouldn't show it in any pickers except the
blocking manager (`AddToBlockListViewController`). Before this commit,
we were showing it in a few places. That might let you sorta-send a
message to a group you'd left.

I enumerated all the places where we have pickers, and what their
behavior should be.

| Description                                                           | Code                                        | Show groups?             | Show left groups?        |
| --------------------------------------------------------------------- | ------------------------------------------- | ------------------------ | ------------------------ |
| Various group member pickers (adding members, group story recipients) | `BaseMemberViewController`                  | No                       | N/A                      |
| Send payment screen                                                   | `PaymentsSendRecipientViewController`       | No                       | N/A                      |
| Gift badging “choose recipient” screen                                | `BadgeGiftingChooseRecipientViewController` | No                       | N/A                      |
| Composer                                                              | `ComposeViewController`                     | Yes, only when searching | No                       |
| Add to block list (in Settings → Privacy)                             | `AddToBlockListViewController`              | Yes, only when searching | Yes, only when searching |
| Share sheet                                                           | `SharingThreadPickerViewController`         | Yes                      | No                       |
| Message forwarding                                                    | `ForwardMessageViewController`              | Yes                      | No                       |
| In-app camera                                                         | `CameraFirstCaptureSendFlow`                | Yes                      | No                       |
| Share group link via Signal                                           | `GroupLinkViewController`                   | Yes                      | No                       |
| Share sticker pack, from in a chat                                    | `StickerPackViewController`                 | Yes                      | No                       |
| Share sticker pack, from sticker management screen                    | `ManageStickersViewController`              | Yes                      | No                       |
| “New Group Story” screen                                              | `NewGroupStoryViewController`               | Yes (exclusively)        | No                       |

This doesn't intend to change the behavior of *deleted* groups. Those
will show up when searching if groups are shown at all. For example, a
deleted group will show in the composer if you search for it just like
any other group. A deleted group will *not* show in the "send payment"
screen because groups are never shown there. Again, the behavior around
deleted groups should remain unchanged.

Co-authored-by: Max Radermacher <max@signal.org>
2022-09-20 14:36:36 +00:00
Harry
ae4837e600
Segment story videos longer than 30s
* initial approach commit, needs cleanup

* Keep >30s videos for non-story recipients, but split for stories

* Some cleanup

* fix too many chats toast offset

* show tooltip in the send flow

* pr feedback
2022-09-16 15:29:44 -07:00
Evan Hahn
4d55d95869 Autofix SwiftLint whitespace issues
I recommend reviewing this with whitespace changes disabled.
2022-09-15 16:37:44 +00:00
Nora Trapp
ae6b55b1bf Hide some extraneous back button labels 2022-09-12 15:35:02 -07:00
Nora Trapp
ad34089ffe Sync group stories with storage service 2022-09-12 12:00:14 -07:00
Nora Trapp
da9f52c67d Update conversation split view styling 2022-09-12 10:48:28 -07:00
Nora Trapp
6dc57c6eb0 Don't allow sending stories to groups you are no longer a member of 2022-09-12 10:38:47 -07:00
Nora Trapp
86be80dbd7 Add story info sheet 2022-09-12 10:36:15 -07:00
Nora Trapp
9bd91f66b6 Allow turning off stories 2022-09-12 10:14:09 -07:00
Nora Trapp
95ddec00b5 Redesigned story privacy settings 2022-09-12 10:14:09 -07:00
Nora Trapp
de0ef9444b Fix some usage of NSLocalizedString 2022-09-11 10:36:23 -07:00
Nora Trapp
66c25a4afd Batch update identity keys and present safety number sheet on camera first and sharing flows 2022-09-08 09:42:43 -07:00
Nora Trapp
92d5207158 Batch lookup safety number changes when selecting conversations from conversation picker 2022-09-08 09:42:43 -07:00
Jordan Rose
3d312796e6
The in-app calling PiP should dodge the keyboard
- Dismissing the keyboard resets the PiP window to its original
  location, unless it's been moved since

- Tested against all of iPad's various keyboard modes (undocked /
  floating keyboards are ignored)
2022-09-07 15:41:23 -07:00
Evan Hahn
1fb1bb297a
Swiftify showUIForLaunchFailure
A pretty mechanical conversion.

There were a few weirder things that I called out in comments.
2022-09-07 14:42:01 -05:00
Nora Trapp
09598d2e7a Add remote flag for stories 2022-08-31 13:34:24 -07:00
Evan Hahn
c77a8022ed Hide blocked contacts from recipient pickers
Because we don't show blocked contacts in the recipient picker, we can
also remove some code that checks for blocked contacts.
2022-08-30 22:36:59 +00:00
Nora Trapp
b420ad1f95 Cleanup AttachmentMultisend 2022-08-19 14:23:59 -07:00
Evan Hahn
48c3c08c10 Fix vertical_parameter_alignment SwiftLint violations
This fixes violations of [SwiftLint's `vertical_parameter_alignment`
rule][0]. This should have no user impact.

[0]: https://realm.github.io/SwiftLint/vertical_parameter_alignment.html
2022-08-18 10:37:09 -05:00
Jordan Rose
0f694d318c Allow ToastController to present from the top as well 2022-08-17 17:59:19 -07:00
Igor Solomennikov
915f3bd4f9
Redo media quality picker sheet in media editor.
• provide visual feedback when user selects media quality.
• add VoiceOver support.
• fix retain cycle caused leak of ActionSheetController objects.
• correct bottom margin on non-notch devices.
2022-08-05 11:03:35 -07:00
Jordan Rose
07067fd03d Be more deliberate about starting/ending orientation notifications
- PhotoCapture's logic was correct, but hard to prove such.
- ScanQRCodeViewController left notifications on for the rest of the
  process lifetime.
- CallService was working around a WebRTC issue that appears to no
  longer be present (per inspection of the WebRTC code).
2022-08-05 08:11:38 -05:00
harry-signal
f305b4a2aa
Allow changing playback rate on OWSAudioPlayer
* Allow changing playback rate on OWSAudioPlayer

* nits and remove audio playback rater getter

* add explicit thread and attachment ID types to CVAudioPlayback cache
2022-08-04 14:55:53 -07:00
Jordan Rose
094c8290ce Remove unnecessary NotificationCenter.removeObserver calls
As of iOS 9, selector-based observers in NotificationCenter do not
need to be explicitly unregistered.
2022-08-02 17:43:52 -07:00
Jordan Rose
4f06a6d8a5 Fix incorrect uses of NotificationCenter block-based API
The block-based API returns a token that needs to be explicitly
unregistered, *and* the block should not capture 'self' strongly.
The fixes in this PR come in three flavors:

1. Switch to the selector-based API, sometimes taking advantage of
   the fact that extra arguments to an Objective-C method can be
   safely discarded (because they are passed at +0).

2. Save the observer token and unregister in deinit.

3. Comment why it's safe to leave the observer registered forever
   in this particular case.
2022-08-02 17:43:52 -07:00
Max Radermacher
03944b813d Remove tableViewStyle 2022-07-28 16:28:33 -07:00
Max Radermacher
c6e0df5607
Fix initial height of table view sheets
When computing the height constraints, the table view wasn’t always
sized properly, which resulted in the wrong initial height.
2022-07-27 15:31:23 -07:00
Igor Solomennikov
32fffd4308 Media Editor: fix an issue when Pen and Crop button might not be visible.
Repro steps:
* have an album of three media: the first two are static, the last one is a video.
* go to the video and tap into message text input to pop the keyboard.
* dismiss keyboard and swipe to the static image.

Expected:
Static image tools buttons to be visible.

Result:
Static image tools buttons not visible.

Issue is a very weird one and likely is caused by some obscure bug with UIKit / UIStackView.
2022-07-25 17:00:56 -07:00
Igor Solomennikov
77d1f2b5ab
Fix regression caused OWSTableSheetViewController not use all available height.
OWSTableViewSheetViewController is inherited from InteractiveSheetViewController
and has additional size calculation logic that updates current sheet size based
on UITableView's contentSize. However, there's also a "max height" constraint
that also needs updating  - this commits adds that.
2022-07-21 09:43:30 -07:00
Evan Hahn
c0c4a85d48 Fix InteractiveSheetViewController scrolling bug
Short story: we now properly decide whether the sheet is being resized
or scrolled, fixing the bug.

Long story:

Some users report that they can't scroll the forward message sheet
([example report 1][1], [example report 2][2]). This wasn't just a bug
with the forwarding sheet. It was a bug with all subclasses of
`InteractiveSheetViewController`.

When you gesture on the sheet, there are effectively two modes: "resize
the sheet mode", and "scroll the contents" mode. (See
`beginInteractiveTransitionIfNecessary` for a boolean that expresses
this.) The logic is effectively this:

    def getMode():
      if sheetHeight < maximumSheetHeight:
        # Note: there are some other ways to get this mode, e.g. by
        # grabbing the handle. But those aren't relevant for this bug.
        return "resize the sheet mode"
      else:
        return "scroll the contents mode"

Unfortunately, there was a bug in how we computed the max sheet height
if that height was larger than the height of the screen (e.g., in
landscape mode or on a shorter device). That bad height caused you to
get into "resize the sheet mode" incorrectly. This fixes that, and does
a few other cleanups.

[1]: https://github.com/signalapp/Signal-iOS/issues/5366
[2]: https://community.signalusers.org/t/beta-feedback-for-the-upcoming-ios-5-44-release/45401/3

Co-Authored-By: Igor Solomennikov <igor@signal.org>
2022-07-19 16:54:57 -05:00
Evan Hahn
486067130c Remove unused AttachmentCaptionViewController
It looks like this was removed in
7f4a5f3f7b.

`git grep -w AttachmentCaptionDelegate` and `git grep -w
AttachmentCaptionViewController` both return no results after removing
this file.
2022-07-15 17:15:53 -05:00
Nora Trapp
c2d9787cf7 PR Feedback 2022-07-15 15:05:03 -07:00
Nora Trapp
b67069e251 Add the editing of private stories 2022-07-15 15:05:03 -07:00
Nora Trapp
192c612bab Allow creation of private stories 2022-07-15 15:05:03 -07:00
Nora Trapp
d9c0a92ed4 Move dependencies needed for private story creation to SignalUI 2022-07-15 15:05:03 -07:00
Nora Trapp
b82cd6c654 Add ability to send to group stories 2022-07-15 15:05:03 -07:00
Nora Trapp
0dae510d07 Add '+ New Story' button to conversation picker 2022-07-15 15:05:03 -07:00
Igor Solomennikov
a71c59b9ad Fix issue making it impossible to activate popup menu in media editor's review screen.
Placeholder text view (the one that displays "Add Message") was stealing
focus and the fix is to disable user interaction for it.
2022-07-14 12:35:29 -07:00
Igor Solomennikov
cb4a9bb9e5 Minor UI fix for the review screen in media editor.
Long recipient name in the top right corner would not be faded at the
end upon initial presentation.
This was happening because subviews did not have their final frames at
the end of `layoutSubviews`.
The fix is to call method that updates fading on next run loop run.
2022-07-14 12:09:35 -07:00
igor-signal
a02c18c972
Animate UI changes in the bottom toolbar in media review screen.
Animate UI changes in the bottom toolbar in media review screen.
2022-07-13 12:12:48 -07:00
igor-signal
8b5ef88a88
Use "translucent dark" style for action sheets in media flow. (#4559) 2022-07-12 19:11:12 -07:00
igor-signal
0c02bf9f29
[Media Editor] Fixes for text field in review screen.
• improvement: correct amount of padding between text field and keyboard.
• fix: text field isn't tall enough when there's a message draft and
  keyboard isn't up.
• fix: onscreen keyboard briefly changes style to 'light' upon dismissal.
2022-07-12 16:13:06 -07:00
igor-signal
c64320e75b
Improve crop view presentation.
Keep image center intact when transitioning to/from crop view to
eliminate unpleasant "jump".
2022-07-12 12:03:55 -07:00
Igor Solomennikov
70f4ab3fab [Media Editor] Do not wrap image editing tool VCs in a nav controller.
Two VCs: photo editor and crop view don't need a UINavigationController
and are fine presented as is.

Also remove unused `completion` parameter.
2022-07-07 15:38:25 -07:00
igor-signal
bf2ce630d9
Fix layout of mention picker in media editor's Review screen. 2022-07-07 11:42:05 -07:00
Igor Solomennikov
7f4a5f3f7b Merge branch igor/media-editor-updates. 2022-07-06 14:54:26 -07:00
Evan Hahn
d0c7de494a Computed accessors shold always be in the same order
`get`, then `set`. This fixes violations of [SwiftLint's
`computed_accessors_order` rule][0].

A very mechanical change.

[0]: https://realm.github.io/SwiftLint/computed_accessors_order.html
2022-06-24 09:35:07 -07:00
Evan Hahn
576d854c6f Remove unnecessary break statements
This fixes all of our violations of [SwiftLint's
`unneeded_break_in_switch` rule][0].

[0]: https://realm.github.io/SwiftLint/unneeded_break_in_switch.html
2022-06-24 09:32:34 -07:00
Sasha Weiss (Signal)
2f4ded9d03
Fix reentrant DB read on mentions processing 2022-06-20 13:21:22 -07:00
Nora Trapp
7bd167f815
Initial story sending support
* Little fix for context menu

* Add 'My Stories' section to stories tab

* Add new story thread types

* Show stories in conversation picker

* Support for sending stories

* Update story list when sending stories

* Add basic 'My Stories' view controller

* Initial stories settings screens

* Consolidate TSPrivateStoryThread and TSMyStoryThread into one class

* Require an explicit read transaction to initialize an outgoing message

* Fix linting

* Allow enabling group story from internal settings

* Fix tests

* PR Feedback
2022-06-10 22:28:03 -04:00
Max Radermacher
66a2638edd Don’t attach canceled link previews 2022-06-09 15:10:50 -07:00
Evan Hahn
c2e7f0ca93 Prefer implicit getters
_I recommend reviewing this with whitespace changes disabled._

This fixes violations of [SwiftLint's `implicit_getter` rule][0] by
removing explicit getters when an implicit one would do.

[0]: https://realm.github.io/SwiftLint/implicit_getter.html
2022-06-06 14:00:15 +00:00
Igor Solomennikov
db0c4e7c73 Fix crash when opening media flow with message pre-populated.
Steps to reproduce:
• open group chat and type a message containing "@" but don't send it.
• tap on + and select last photo/video from the strip.
• observe app crashing.

Cause of crash:
Attempting to access a child view controller of UIPageViewController
while using force unwrap when UIPageViewController's view is not yet loaded.

The fix:
• Remove force unwrapping (linter was complaining about that too).
• Add "isViewLoaded" check to the method that was causing the crash.
2022-05-25 11:42:04 -07:00
Evan Hahn
29c0ddf60e Fix violations of SwiftLint's attributes rule
_I recommend reviewing this with whitespace changes disabled._

Most of these were `@objc` being on the same line, which I fixed with [a
silly script][1]—probably could've used `sed` if I were wiser. The rest
were manual fixes.

See [the SwiftLint documentation for this rule][0].

[0]: https://realm.github.io/SwiftLint/attributes.html
[1]: https://gist.github.com/EvanHahn-Signal/d353c93fa269c82b96baca0a1086521f
2022-05-14 09:07:42 -05:00
Evan Hahn
df8592fa23 Fix SwiftLint switch_case_alignment violations
_I recommend reviewing this with whitespace changes disabled._

Bad:

```swift
switch foo {
    case .one: return 1
    case .two: return 2
}
```

Good:

```swift
switch foo {
case .one: return 1
case .two: return 2
}
```

See [the rule's documentation][0] for more.

[0]: https://realm.github.io/SwiftLint/switch_case_alignment.html
2022-05-03 12:15:05 -05:00
igor-signal
4a6473b448
Localize user-visible file sizes.
Use ByteCountFormatter with default settings to localize any download sizes that user might see.
2022-04-29 09:57:56 -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
Igor Solomennikov
dc19eb835f Fix "the the" in comments. 2022-04-27 20:16:45 -07:00
Igor Solomennikov
8fe9963f16 Address PR feedback. 2022-04-22 11:15:21 -07:00
Igor Solomennikov
9349af7fa5 Fix incorrect (old) media editor layout in landscape on non-plus size devices. 2022-04-22 11:15:21 -07:00
Michelle Linington
37fe097812 Lint 2022-04-13 20:23:22 -07:00
Michelle Linington
d54d654cfc PR Feedback: Remove notImplemented altogether 2022-04-13 20:21:47 -07:00
Michelle Linington
6b2f8d31d6 Lint 2022-04-13 20:21:46 -07:00
Michelle Linington
cca09295e6 Adopt notImplemented() where it's unadopted
notImplemented() ends up forwarding to fatalError() anyway, but before
it does so it flushes our logs. That's probably good to have. I think
most of these come from the default implementations Xcode provides for
you with a fix-it.
2022-04-13 20:21:46 -07:00
Evan Hahn
8b072620a6 Add "Donation Receipts" view 2022-04-11 16:21:12 -05:00
Michelle Linington
dd0a7f6b80 Require transaction to check blocked address state 2022-04-08 19:01:43 -07:00
Michelle Linington
739af9372a Require transaction to check blocked thread state 2022-04-08 19:01:43 -07:00
Igor Solomennikov
95d6a96824 Update checkmark in chat picker from media sharing flow to match other views.
ConversationPicker shared checkmark asset with media editor toolbar. The
checkmark was a little bit too small, also checked and unchecked indicators
had different size.

This commit updates ConversationPicker to use the same checkmark styling
that group UI has.
2022-03-29 10:12:29 -07:00
Igor Solomennikov
d9acd69963 [MediaEditor] Fix typo that caused broken layout when in landscape mode. 2022-03-22 14:24:13 -07:00
Igor Solomennikov
007415832e Disable Send/Proceed button if no chats are selected. 2022-03-22 10:56:46 -07:00
Dimitris Apostolou
62724cf0be Fix typos 2022-03-18 11:31:06 -07:00
Martin Böttcher
000c4c282b Merge branch 'master' into martin/IOS-2234 2022-03-17 09:09:37 +01:00
Nora Trapp
52a3182f13 Render story rings on avatars 2022-03-16 17:52:43 -07:00
Martin Böttcher
8f9be31ba3 replaced NSLocalizedStringFromAppBundle with OWSLocalizedString 2022-03-08 10:17:25 +01:00
Martin Böttcher
c0adfbfb32 NSLocalizedString is replaced by NSLocalizedStringFromAppBundle (reading strings from the bundle of the main app) for all source files called by an app extension and the localizable files are removed for the app extension targets. 2022-03-07 13:29:06 +01:00
Chris Eager
d92eaf97d5 lint fixes 2022-03-04 15:41:21 -08:00
Chris Eager
fa8e829115 Move CaptchaView to its own file 2022-03-04 15:41:21 -08:00
Chris Eager
b33a623e28 Add support for staging captcha URLs 2022-03-04 15:41:21 -08:00
Igor Solomennikov
96c7b802de Slightly tweak position of photos/videos in media editor.
In order to minimize amount of moving elements when transitioning from
in-app camera to media editor.
2022-03-02 17:58:40 -08:00
Igor Solomennikov
f8824905c9 Remove OWSNavigationController.ows_preferredStatusBarStyle.
Turns out it is not really necessary: a subclassed UINavigationController
is presented and `preferredStatusBarStyle` override works just fine.
2022-03-02 17:56:40 -08:00
Igor Solomennikov
a48c40b2ba Make status bar visible when media sharing UI is presented.
Media sharing UI is implemented in dark-only style which means
status bar needs to be updated to be visible if the rest of application UI
is in light mode.
2022-03-02 17:56:39 -08:00
Jordan Rose
058a0213b7 Check whether you're blocked in a thread without a write transaction
In most cases when working with a ConversationItem we already have a
write transaction, but sometimes we don't. In this case, we know you
can only be blocked in a conversation if there's history in it (at
least as far as the local device knows), and so we can ignore any
threads that don't exist.
2022-02-18 14:00:27 -08:00
Igor Solomennikov
6c037a84af Fix typo in a comment. 2022-01-31 17:57:15 -08:00
Igor Solomennikov
d1a726f467 Do not use UIVC.automaticallyAdjustsScrollViewInsets - deprecated.
Use UIScrollView.contentInsetAdjustmentBehavior instead.
2022-01-31 15:41:18 -08:00
Igor Solomennikov
6848210a4c Remove UIScrollView workaround that was only used in iOS 11.0-11.2
Not needed anymore since min supported iOS version is now 12.2
2022-01-31 15:15:18 -08:00
Igor Solomennikov
ec96c7a1c6 Do not use UIVC.topLayoutGuide and UIVC.bottomLayoutGuide.
Both are deprecated in iOS 12.
2022-01-31 15:15:18 -08:00
Michelle Linington
f29d37f381 Merge branch 'release/5.27.0' 2022-01-26 12:21:38 -08:00
Martin Böttcher
fcbd352462 renamed some properties and arguments; removed orphaned protocol 2022-01-26 10:46:08 +01:00
Martin Böttcher
777c9785a2 refactored background color handling (part of cell configuration), fixed colors searching on iPad, changed handling of theme change during multi-selection 2022-01-26 10:46:08 +01:00
Martin Böttcher
625fc41416 cell background and context menu react to Theme changes 2022-01-26 10:46:08 +01:00
Martin Böttcher
738cb3c198 home view cells and toolbar reacts to Theme change 2022-01-26 10:46:08 +01:00
Nora Trapp
a2f51dc4a3 Cleanup old feature flags 2022-01-24 10:53:55 -08:00
Martin Böttcher
d5d688f0c7 background and selected background of HomeViewCells got broken if reused 2022-01-21 10:29:47 +01:00
Eugene Bistolas
a60d89afdb Support emoji search in the emoji picker sheet 2021-12-10 13:03:55 -10:00
Matthew Chen
fc749b4d72 Change phone number. 2021-11-19 14:28:18 -03:00
Michelle Linington
13ad8dbac1 Add badge collection to conversation settings 2021-11-17 15:22:14 -08:00
Nora Trapp
7ecb98e935 PR Feedback 2021-11-10 11:16:52 -08:00
Nora Trapp
ba8154ff7b Fix conversation picker search bar styling 2021-11-10 11:10:18 -08:00
Michelle Linington
6105ee5a20 Better naming of size classes
Also fixes bug with EmojiReactorCell layout
2021-11-09 14:25:55 -08:00
Michelle Linington
dea35199b2 Clean up ConversationAvatarView data sources
Creates a special data source enum for ConversationAvatarView data
providers. Before, ContactCell and ConversationAvatarView used the data
source, neither applying to each perfectly
2021-11-09 14:25:55 -08:00
Michelle Linington
9f53832e14 Remove usage of ConversationAvatarView 2021-11-09 14:25:55 -08:00
Nora Trapp
08e8da9c5c Fix conversation picker search results 2021-11-08 17:16:53 -08:00
Matthew Chen
007a00a17b Add PhoneNumberUtil singleton. 2021-10-22 19:06:15 -03:00
Matthew Chen
a0efdc2e95 Respond to CR. 2021-10-21 09:21:33 -03:00
Matthew Chen
91ad7d1df7 Respond to CR. 2021-10-21 09:21:31 -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
Matthew Chen
57f8212495 Add SignalUI framework target. 2021-10-19 09:39:53 -03:00
Matthew Chen
25f015d8bc Add SignalUI framework target. 2021-10-19 09:39:53 -03:00
Matthew Chen
21a8175795 Add SignalUI framework target. 2021-10-19 09:39:53 -03:00
Matthew Chen
fbde0356f7 Add SignalUI framework target. 2021-10-19 09:39:53 -03:00
Matthew Chen
b27457ecc6 Add SignalUI framework target. 2021-10-19 09:39:53 -03:00
Matthew Chen
c416609108 Add SignalUI framework target. 2021-10-19 09:39:53 -03:00