Commit Graph

254 Commits

Author SHA1 Message Date
Max Radermacher
6ab952d3a8
Pass data to the correct CocoaLumberjack fields 2023-11-17 16:39:40 -06:00
Max Radermacher
46ed408517
Remove some unused code 2023-11-15 18:24:20 -06:00
Sasha Weiss
883cd6a976
Rename LightweightCallManager to LightweightGroupCallManager 2023-10-12 14:48:43 -07:00
Harry
aa0e250cb7
[Death to TSAccountManager, long live TSAccountManager][9] Migrate usages of old TSAccountManager to new 2023-10-05 08:56:08 -07:00
Harry
f9cecdfb2b
Split apart PreKeyTask to allow independently generating, uploading, and persisting prekeys 2023-08-09 16:23:32 -07:00
Harry
501ee85adf
Refresh SVR2 auth credentials every new app version 2023-07-31 18:02:07 -07:00
Pete Walters
4356b505b2
Migrate TSPreKeyManager to Swift 2023-07-27 21:02:33 -05:00
Max Radermacher
590d70d118
Show error in share ext if you’re deregistered 2023-07-27 20:19:20 -05:00
Harry
f728457039
Update build target to iOS 13.0 2023-06-08 16:21:20 -07:00
Igor Solomennikov
c0b01db156
Convert Environment from SignalMessaging to Swift as SMEnvironment. 2023-06-02 20:53:07 -07:00
Igor Solomennikov
488bb72de7
Remove unnecessary "@objc" in Share Ext and NSE. 2023-05-16 16:35:42 -07:00
Max Radermacher
4887120cb8
Move OWSOrphanDataCleaner out of SignalMessaging 2023-05-04 17:49:48 -07:00
Max Radermacher
0def4f62f0
Swiftify some DebugLogger code 2023-05-02 16:41:46 -07:00
Igor Solomennikov
e9eefda2d9
Convert screen lock related classes to Swift.
Co-authored-by: Max Radermacher <max@signal.org>
2023-05-02 12:06:40 -07:00
Evan Hahn
d9d6ce3ea4
Move AppExpiry off Dependencies and NSObject 2023-04-20 12:46:21 -05:00
Max Radermacher
92e170fe12
Swiftify SSKEnvironment 2023-04-14 10:58:21 -07:00
Max Radermacher
66362e050d
Introduce LocalIdentifiers…
…a struct containing your own ACI, PNI, and phone number.
2023-04-12 18:36:45 -07:00
Max Radermacher
4891a4beea
Split AppSetup into discrete method calls 2023-04-12 18:18:25 -07:00
Max Radermacher
25825edd07 Swiftify some TSAccountManager code 2023-04-12 18:05:36 -07:00
Max Radermacher
22ef2d8e55
Swiftify AppSetup 2023-04-12 17:54:48 -07:00
Max Radermacher
7060637cae
Clean up state transitions on app launch 2023-04-06 17:41:08 -07:00
Evan Hahn
3804ed76a5
Move app version off Dependencies and NSObject
This change should have no user impact.

`appVersion` used to be a property of `Dependencies` and `NSObject`. It
just deferred to `AppVersion.shared()`.

This commit removes those properties and relies on `AppVersion.shared`
instead. Also, `AppVersion.shared` is now a getter, not a function.
2023-04-05 13:29:49 -07:00
Sasha Weiss
07385663e5
Mark .richText as stories compatible in share extension 2023-03-02 18:57:54 -08:00
Sasha Weiss
be92c40068
Handle attributed text from RTF item providers in share extension 2023-03-01 09:08:59 -08:00
Max Radermacher
218663e430
Fix when ExitShareExtension gets called 2023-02-24 00:55:42 -08:00
Harry
003cc19e62
Update SignalCoreKit. Use explicit DispatchQueue instead of relying on the implicit type on promise 'on' params
* Use explicit DispatchQueue instead of relying on the implicit type on promise 'on' params

* Update SignalCoreKit
2023-02-07 16:14:39 -08:00
Harry
5824871af9
Share sheet: allow sharing to story before processing completes 2022-11-16 10:28:06 -06:00
Evan Hahn
a941c82c14
Prefer isEmpty with strings
This change may improve performance slightly but should have no other
user impact.

`myString.isEmpty` is faster than `myString.count == 0` or equivalent,
because computing `count` may require iterating over the string.

I tried to fix all occurrences of this.

Tested this by sending a message in a group and doing a full
re-registration, just in case I broke something there.
2022-11-01 17:53:46 -05: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
Max Radermacher
974b643234
Reduce likelihood of flaky test failures 2022-10-07 09:36:04 -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
Igor Solomennikov
7f4a5f3f7b Merge branch igor/media-editor-updates. 2022-07-06 14:54:26 -07:00
igor-signal
e3d528ba2a
Fix "Unused Optional Binding" violations 2022-06-23 12:55:31 +00:00
Sasha Weiss (Signal)
5695809776
Prevent non-temporary-file attachments from being deleted when shared 2022-06-22 13:15:04 -07:00
Max Radermacher
b1874b4c5f Fix some _isDebugAssertConfiguration warnings
By moving the check after the `isLoggingEnabled()` check, there isn’t
unreachable code, so the compiler warning goes away. (The `_isDebug…`
check has to be second, or the `isLoggingEnabled()` call would be
unreachable code.)

For the other case, I wrapped the entire check in a single `assert`,
avoiding the `_isDebugAssertConfiguration` call altogether. (This one
wasn’t a warning, but I think this approach is more canonical, and it’s
probably best to avoid `_` functions where possible.)
2022-05-06 09:48:50 -05:00
Igor Solomennikov
dc19eb835f Fix "the the" in comments. 2022-04-27 20:16:45 -07:00
Dimitris Apostolou
62724cf0be Fix typos 2022-03-18 11:31:06 -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
Michelle Linington
259cf01376 Lint 2022-03-04 14:16:29 -08:00
Michelle Linington
62e804da5f Plumbing 2022-03-04 14:16:29 -08:00
Matthew Chen
c0c72ef3fb Introduce WebSocketFactory. 2021-11-03 19:48:48 -07:00
Matthew Chen
539dff09e4 Move MobileCoin SDK to SignalUI. 2021-11-02 14:26:03 -03:00
Michelle Linington
77b7ea5c40 Fix a whole bunch of warnings 2021-10-21 21:11:26 -07:00
Matthew Chen
05940be99d Respond to CR. 2021-10-19 09:40:26 -03:00
Matthew Chen
c416609108 Add SignalUI framework target. 2021-10-19 09:39:53 -03:00
Matthew Chen
b9b66646ff Add SignalUI framework target. 2021-10-19 09:39:52 -03:00
Matthew Chen
d402636225 Simplify AFNetworking usage. 2021-10-15 10:50:35 -03:00
Nora Trapp
2814ab7629 Convert to new Promise library 2021-09-03 11:41:34 -07:00
Artem Varaksa
7378eff81d Allow sharing items with UTI com.apple.pkpass. 2021-08-18 15:26:26 -07:00