diff --git a/Podfile b/Podfile index c9f932438..1e56ca8dc 100644 --- a/Podfile +++ b/Podfile @@ -12,8 +12,8 @@ def shared_pods #pod 'HKDFKit', path: '../HKDFKit' pod 'Curve25519Kit', git: 'https://github.com/WhisperSystems/Curve25519Kit', branch: 'mkirk/framework-friendly' #pod 'Curve25519Kit', path: '../Curve25519Kit' + # FIXME SHARINGEXTENSION use up-to-date framework compatible OpenSSL #pod 'OpenSSL', git: 'https://github.com/WhisperSystems/OpenSSL-Pod', inhibit_warnings: true - # TODO switch OpenSSL lib pod 'GRKOpenSSLFramework' # third party pods diff --git a/Signal/src/AppDelegate.m b/Signal/src/AppDelegate.m index a85319872..5f2707044 100644 --- a/Signal/src/AppDelegate.m +++ b/Signal/src/AppDelegate.m @@ -123,6 +123,8 @@ static NSString *const kURLHostVerifyPrefix = @"verify"; // This block will be cleared in databaseViewRegistrationComplete. [DeviceSleepManager.sharedInstance addBlockWithBlockObject:self]; + // TODO this code is just to prove that the embedded framework is accessible from + // the main app. DDLogVerbose(@"%@ shared path: %@", self.logTag, [[StorageCoordinator shared] path]); [self setupEnvironment]; diff --git a/SignalMessaging/StorageCoordinator.swift b/SignalMessaging/StorageCoordinator.swift index 91bbb47c2..f09e9b0a0 100644 --- a/SignalMessaging/StorageCoordinator.swift +++ b/SignalMessaging/StorageCoordinator.swift @@ -4,6 +4,11 @@ import Foundation +/** + * This class doesn't actually do anything (yet?). + * It's just an example class to prove the embedded framework is correctly + * integrated with Signal-iOS and the Sharing Extension. + */ @objc public class StorageCoordinator: NSObject { diff --git a/SignalServiceKit.podspec b/SignalServiceKit.podspec index 9c3d8a2dd..0e7251bef 100644 --- a/SignalServiceKit.podspec +++ b/SignalServiceKit.podspec @@ -38,7 +38,7 @@ An Objective-C library for communicating with the Signal messaging service. s.dependency 'YapDatabase/SQLCipher', '~> 2.9.3' s.dependency 'SocketRocket' s.dependency 'libPhoneNumber-iOS' - # TODO use framework compatible OpenSSL + # FIXME SHARINGEXTENSION use up-to-date framework compatible OpenSSL #s.dependency 'OpenSSL' s.dependency 'GRKOpenSSLFramework' s.dependency 'SAMKeychain' diff --git a/SignalShareExtension/ShareViewController.swift b/SignalShareExtension/ShareViewController.swift index 87ed190f8..76ac57d86 100644 --- a/SignalShareExtension/ShareViewController.swift +++ b/SignalShareExtension/ShareViewController.swift @@ -7,16 +7,31 @@ import Social import SignalMessaging import PureLayout +import SignalServiceKit class ShareViewController: SLComposeServiceViewController { override func viewDidLoad() { super.viewDidLoad() + + // None of the following code is intended to be used, it only serves to prove + // the project has been configured correctly + + // Proof of cocoapods, utilizes PureLayout let someView = UIView() someView.backgroundColor = UIColor.green view.addSubview(someView) someView.autoPinEdgesToSuperviewEdges() - self.placeholder = StorageCoordinator.shared.path + someView.alpha = 0.2 + + let proofOfSharedFramework = StorageCoordinator.shared.path + let proofOfSSK = textSecureServerURL + + // TODO: Shared Storage via app container + //let proofOfSharedStorage = TSAccountManager.localNumber() + let proofOfSharedStorage = "TODO" + + self.placeholder = "shared framework: \(proofOfSharedFramework) \n sharedStorage: \(proofOfSharedStorage) \n proof of ssk: \(proofOfSSK)" } override func isContentValid() -> Bool {