diff --git a/Classes/Manager/FLEXManager+Extensibility.m b/Classes/Manager/FLEXManager+Extensibility.m index 0872ee66ff..69383d1b0a 100644 --- a/Classes/Manager/FLEXManager+Extensibility.m +++ b/Classes/Manager/FLEXManager+Extensibility.m @@ -86,19 +86,19 @@ + (void)registerFieldNames:(NSArray *)names forTypeEncoding:(NSStrin #pragma mark - Simulator Shortcuts - (void)registerSimulatorShortcutWithKey:(NSString *)key modifiers:(UIKeyModifierFlags)modifiers action:(dispatch_block_t)action description:(NSString *)description { -#if TARGET_OS_SIMULATOR +#if TARGET_OS_SIMULATOR || TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 [FLEXKeyboardShortcutManager.sharedManager registerSimulatorShortcutWithKey:key modifiers:modifiers action:action description:description allowOverride:YES]; #endif } - (void)setSimulatorShortcutsEnabled:(BOOL)simulatorShortcutsEnabled { -#if TARGET_OS_SIMULATOR +#if TARGET_OS_SIMULATOR || TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 [FLEXKeyboardShortcutManager.sharedManager setEnabled:simulatorShortcutsEnabled]; #endif } - (BOOL)simulatorShortcutsEnabled { -#if TARGET_OS_SIMULATOR +#if TARGET_OS_SIMULATOR || TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 return FLEXKeyboardShortcutManager.sharedManager.isEnabled; #else return NO; @@ -109,7 +109,7 @@ - (BOOL)simulatorShortcutsEnabled { #pragma mark - Shortcuts Defaults - (void)registerDefaultSimulatorShortcutWithKey:(NSString *)key modifiers:(UIKeyModifierFlags)modifiers action:(dispatch_block_t)action description:(NSString *)description { -#if TARGET_OS_SIMULATOR +#if TARGET_OS_SIMULATOR || TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 // Don't allow override to avoid changing keys registered by the app [FLEXKeyboardShortcutManager.sharedManager registerSimulatorShortcutWithKey:key modifiers:modifiers action:action description:description allowOverride:NO]; #endif diff --git a/Classes/Utility/Keyboard/FLEXKeyboardHelpViewController.m b/Classes/Utility/Keyboard/FLEXKeyboardHelpViewController.m index 66e9d7e694..8b91f116e5 100644 --- a/Classes/Utility/Keyboard/FLEXKeyboardHelpViewController.m +++ b/Classes/Utility/Keyboard/FLEXKeyboardHelpViewController.m @@ -23,7 +23,7 @@ - (void)viewDidLoad { self.textView = [[UITextView alloc] initWithFrame:self.view.bounds]; self.textView.autoresizingMask = UIViewAutoresizingFlexibleWidth|UIViewAutoresizingFlexibleHeight; [self.view addSubview:self.textView]; -#if TARGET_OS_SIMULATOR +#if TARGET_OS_SIMULATOR || TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 self.textView.text = FLEXKeyboardShortcutManager.sharedManager.keyboardShortcutsDescription; #endif self.textView.backgroundColor = UIColor.blackColor; diff --git a/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m b/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m index 4263245de3..f9cb799340 100644 --- a/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m +++ b/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m @@ -11,7 +11,7 @@ #import #import -#if TARGET_OS_SIMULATOR +#if TARGET_OS_SIMULATOR || TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 @interface UIEvent (UIPhysicalKeyboardEvent) diff --git a/Example/FLEXample-Cocoapods.xcodeproj/project.pbxproj b/Example/FLEXample-Cocoapods.xcodeproj/project.pbxproj index 6535bb4953..78321b1580 100644 --- a/Example/FLEXample-Cocoapods.xcodeproj/project.pbxproj +++ b/Example/FLEXample-Cocoapods.xcodeproj/project.pbxproj @@ -28,6 +28,7 @@ /* End PBXBuildFile section */ /* Begin PBXFileReference section */ + 544D11A52819CDE500FED6C9 /* FLEXample.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = FLEXample.entitlements; sourceTree = ""; }; 92E1E1EECA3F2533E1B8BF35 /* Pods-FLEXample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-FLEXample.debug.xcconfig"; path = "Target Support Files/Pods-FLEXample/Pods-FLEXample.debug.xcconfig"; sourceTree = ""; }; BBD699DDBAC5A16D8CFD39AC /* libPods-FLEXample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-FLEXample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; BE1780244AEC542DDB894B08 /* Pods-FLEXample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-FLEXample.release.xcconfig"; path = "Target Support Files/Pods-FLEXample/Pods-FLEXample.release.xcconfig"; sourceTree = ""; }; @@ -81,6 +82,7 @@ EB0852B7D285AB31D7532049 /* Pods */, ); sourceTree = ""; + usesTabs = 0; }; C386D6CD2419975A00699085 /* Products */ = { isa = PBXGroup; @@ -120,6 +122,7 @@ C386D6DA2419975B00699085 /* LaunchScreen.storyboard */, C386D6DD2419975B00699085 /* Info.plist */, C386D6E32419984700699085 /* FLEXample-Bridging-Header.h */, + 544D11A52819CDE500FED6C9 /* FLEXample.entitlements */, ); path = "Supporting Files"; sourceTree = ""; @@ -429,6 +432,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; + CODE_SIGN_ENTITLEMENTS = "FLEXample/Supporting Files/FLEXample.entitlements"; CODE_SIGN_STYLE = Automatic; DEVELOPMENT_ASSET_PATHS = "\"FLEXample/Supporting Files/Preview Content\""; DEVELOPMENT_TEAM = ""; @@ -441,6 +445,7 @@ ); PRODUCT_BUNDLE_IDENTIFIER = com.flipboard.flex.FLEXample; PRODUCT_NAME = "$(TARGET_NAME)"; + SUPPORTS_MACCATALYST = YES; SWIFT_OBJC_BRIDGING_HEADER = "FLEXample/Supporting Files/FLEXample-Bridging-Header.h"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 5.0; @@ -454,6 +459,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; + CODE_SIGN_ENTITLEMENTS = "FLEXample/Supporting Files/FLEXample.entitlements"; CODE_SIGN_STYLE = Automatic; DEVELOPMENT_ASSET_PATHS = "\"FLEXample/Supporting Files/Preview Content\""; DEVELOPMENT_TEAM = ""; @@ -466,6 +472,7 @@ ); PRODUCT_BUNDLE_IDENTIFIER = com.flipboard.flex.FLEXample; PRODUCT_NAME = "$(TARGET_NAME)"; + SUPPORTS_MACCATALYST = YES; SWIFT_OBJC_BRIDGING_HEADER = "FLEXample/Supporting Files/FLEXample-Bridging-Header.h"; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; diff --git a/Example/FLEXample-SPM.xcodeproj/project.pbxproj b/Example/FLEXample-SPM.xcodeproj/project.pbxproj index 14e4a27586..4140c2e789 100644 --- a/Example/FLEXample-SPM.xcodeproj/project.pbxproj +++ b/Example/FLEXample-SPM.xcodeproj/project.pbxproj @@ -7,6 +7,7 @@ objects = { /* Begin PBXBuildFile section */ + 544D11A22819CA7D00FED6C9 /* FLEX in Frameworks */ = {isa = PBXBuildFile; productRef = 544D11A12819CA7D00FED6C9 /* FLEX */; }; C386D6D02419975A00699085 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = C386D6CF2419975A00699085 /* AppDelegate.swift */; }; C386D6D22419975A00699085 /* SceneDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = C386D6D12419975A00699085 /* SceneDelegate.swift */; }; C386D6D62419975B00699085 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = C386D6D52419975B00699085 /* Assets.xcassets */; }; @@ -21,13 +22,14 @@ C386D705241AA61600699085 /* music_library_schema.jpg in Resources */ = {isa = PBXBuildFile; fileRef = C386D703241AA61600699085 /* music_library_schema.jpg */; }; C386D70B241AA67800699085 /* Dog.m in Sources */ = {isa = PBXBuildFile; fileRef = C386D709241AA67800699085 /* Dog.m */; }; C386D70C241AA67800699085 /* Owner.m in Sources */ = {isa = PBXBuildFile; fileRef = C386D70A241AA67800699085 /* Owner.m */; }; - C38D96EC2818F306008709D0 /* Reflex in Frameworks */ = {isa = PBXBuildFile; productRef = C38D96EB2818F306008709D0 /* Reflex */; }; C3A67856241AB8AD005A4681 /* MiscNetworkRequests.m in Sources */ = {isa = PBXBuildFile; fileRef = C3A67855241AB8AD005A4681 /* MiscNetworkRequests.m */; }; C3A67858241ADDF7005A4681 /* Commit.swift in Sources */ = {isa = PBXBuildFile; fileRef = C3A67857241ADDF7005A4681 /* Commit.swift */; }; C3B3760025B8CDA300AD43AB /* Person.m in Sources */ = {isa = PBXBuildFile; fileRef = C3B375FF25B8CDA300AD43AB /* Person.m */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ + 544D11A02819CA5600FED6C9 /* FLEX */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = FLEX; path = ..; sourceTree = ""; }; + 544D11A32819CCC800FED6C9 /* FLEXample.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = FLEXample.entitlements; sourceTree = ""; }; BBD699DDBAC5A16D8CFD39AC /* libPods-FLEXample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-FLEXample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; C386D6CC2419975A00699085 /* FLEXample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = FLEXample.app; sourceTree = BUILT_PRODUCTS_DIR; }; C386D6CF2419975A00699085 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; @@ -62,7 +64,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - C38D96EC2818F306008709D0 /* Reflex in Frameworks */, + 544D11A22819CA7D00FED6C9 /* FLEX in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -76,8 +78,10 @@ C3A67853241AB88F005A4681 /* Realm */, C386D6CD2419975A00699085 /* Products */, DCEB5037DA3D5C01CB9CEE93 /* Frameworks */, + 544D11A02819CA5600FED6C9 /* FLEX */, ); sourceTree = ""; + usesTabs = 0; }; C386D6CD2419975A00699085 /* Products */ = { isa = PBXGroup; @@ -117,6 +121,7 @@ C386D6DA2419975B00699085 /* LaunchScreen.storyboard */, C386D6DD2419975B00699085 /* Info.plist */, C386D6E32419984700699085 /* FLEXample-Bridging-Header.h */, + 544D11A32819CCC800FED6C9 /* FLEXample.entitlements */, ); path = "Supporting Files"; sourceTree = ""; @@ -183,7 +188,7 @@ ); name = FLEXample; packageProductDependencies = ( - C38D96EB2818F306008709D0 /* Reflex */, + 544D11A12819CA7D00FED6C9 /* FLEX */, ); productName = FLEXample; productReference = C386D6CC2419975A00699085 /* FLEXample.app */; @@ -215,7 +220,6 @@ ); mainGroup = C386D6C32419975A00699085; packageReferences = ( - C38D96EA2818F306008709D0 /* XCRemoteSwiftPackageReference "Reflex" */, ); productRefGroup = C386D6CD2419975A00699085 /* Products */; projectDirPath = ""; @@ -396,9 +400,10 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; + CODE_SIGN_ENTITLEMENTS = "FLEXample/Supporting Files/FLEXample.entitlements"; CODE_SIGN_STYLE = Automatic; DEVELOPMENT_ASSET_PATHS = "\"FLEXample/Supporting Files/Preview Content\""; - DEVELOPMENT_TEAM = S6N2F22V2Z; + DEVELOPMENT_TEAM = ""; ENABLE_PREVIEWS = YES; INFOPLIST_FILE = "FLEXample/Supporting Files/Info.plist"; IPHONEOS_DEPLOYMENT_TARGET = 13.0; @@ -408,6 +413,7 @@ ); PRODUCT_BUNDLE_IDENTIFIER = com.flipboard.flex.FLEXample; PRODUCT_NAME = "$(TARGET_NAME)"; + SUPPORTS_MACCATALYST = YES; SWIFT_OBJC_BRIDGING_HEADER = "FLEXample/Supporting Files/FLEXample-Bridging-Header.h"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 5.0; @@ -420,9 +426,10 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; + CODE_SIGN_ENTITLEMENTS = "FLEXample/Supporting Files/FLEXample.entitlements"; CODE_SIGN_STYLE = Automatic; DEVELOPMENT_ASSET_PATHS = "\"FLEXample/Supporting Files/Preview Content\""; - DEVELOPMENT_TEAM = S6N2F22V2Z; + DEVELOPMENT_TEAM = ""; ENABLE_PREVIEWS = YES; INFOPLIST_FILE = "FLEXample/Supporting Files/Info.plist"; IPHONEOS_DEPLOYMENT_TARGET = 13.0; @@ -432,6 +439,7 @@ ); PRODUCT_BUNDLE_IDENTIFIER = com.flipboard.flex.FLEXample; PRODUCT_NAME = "$(TARGET_NAME)"; + SUPPORTS_MACCATALYST = YES; SWIFT_OBJC_BRIDGING_HEADER = "FLEXample/Supporting Files/FLEXample-Bridging-Header.h"; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; @@ -461,22 +469,10 @@ }; /* End XCConfigurationList section */ -/* Begin XCRemoteSwiftPackageReference section */ - C38D96EA2818F306008709D0 /* XCRemoteSwiftPackageReference "Reflex" */ = { - isa = XCRemoteSwiftPackageReference; - repositoryURL = "file:///Users/tanner/Repos/Reflex"; - requirement = { - branch = master; - kind = branch; - }; - }; -/* End XCRemoteSwiftPackageReference section */ - /* Begin XCSwiftPackageProductDependency section */ - C38D96EB2818F306008709D0 /* Reflex */ = { + 544D11A12819CA7D00FED6C9 /* FLEX */ = { isa = XCSwiftPackageProductDependency; - package = C38D96EA2818F306008709D0 /* XCRemoteSwiftPackageReference "Reflex" */; - productName = Reflex; + productName = FLEX; }; /* End XCSwiftPackageProductDependency section */ }; diff --git a/Example/FLEXample/Supporting Files/FLEXample.entitlements b/Example/FLEXample/Supporting Files/FLEXample.entitlements new file mode 100644 index 0000000000..8f330422e9 --- /dev/null +++ b/Example/FLEXample/Supporting Files/FLEXample.entitlements @@ -0,0 +1,12 @@ + + + + + com.apple.security.app-sandbox + + com.apple.security.network.client + + com.apple.security.personal-information.photos-library + + +