From 1c913540dfa98b23cf2213cbb3ccf40b7a3d8327 Mon Sep 17 00:00:00 2001 From: Iulian Onofrei Date: Fri, 29 Apr 2022 18:04:04 +0100 Subject: [PATCH] Remove superfluous implementation --- Classes/Manager/FLEXManager+Extensibility.h | 5 ----- Classes/Manager/FLEXManager+Extensibility.m | 8 -------- Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.h | 4 ---- Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m | 10 ---------- Example/FLEXample/AppDelegate.swift | 6 ------ 5 files changed, 33 deletions(-) diff --git a/Classes/Manager/FLEXManager+Extensibility.h b/Classes/Manager/FLEXManager+Extensibility.h index edb36ff977..1a71a0e372 100644 --- a/Classes/Manager/FLEXManager+Extensibility.h +++ b/Classes/Manager/FLEXManager+Extensibility.h @@ -73,11 +73,6 @@ NS_ASSUME_NONNULL_BEGIN action:(dispatch_block_t)action description:(NSString *)description; -#if TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 -/// Gets the default and custom keyboard shortcuts commands. -- (NSArray *)getKeyCommands; -#endif - @end NS_ASSUME_NONNULL_END diff --git a/Classes/Manager/FLEXManager+Extensibility.m b/Classes/Manager/FLEXManager+Extensibility.m index a379584102..8313c15fe6 100644 --- a/Classes/Manager/FLEXManager+Extensibility.m +++ b/Classes/Manager/FLEXManager+Extensibility.m @@ -97,14 +97,6 @@ - (BOOL)simulatorShortcutsEnabled { #endif } -#if TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 - -- (NSArray *)getKeyCommands { - return [FLEXKeyboardShortcutManager.sharedManager getKeyCommands]; -} - -#endif - #pragma mark - Shortcuts Defaults diff --git a/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.h b/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.h index db9bfd994b..292f3d4c68 100644 --- a/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.h +++ b/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.h @@ -26,8 +26,4 @@ @property (nonatomic, getter=isEnabled) BOOL enabled; @property (nonatomic, readonly) NSString *keyboardShortcutsDescription; -#if TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 -- (NSArray *)getKeyCommands; -#endif - @end diff --git a/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m b/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m index 0a72df81b6..f9cb799340 100644 --- a/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m +++ b/Classes/Utility/Keyboard/FLEXKeyboardShortcutManager.m @@ -321,16 +321,6 @@ - (NSString *)keyboardShortcutsDescription { return [description copy]; } -#if TARGET_OS_MACCATALYST || TARGET_CPU_ARM64 - -- (NSArray *)getKeyCommands { - return [self.actionsForKeyInputs.allKeys flex_mapped:^UIKeyCommand *(FLEXKeyInput *keyInput, NSUInteger index) { - return [UIKeyCommand keyCommandWithInput:keyInput.key modifierFlags:keyInput.flags action:nil]; - }]; -} - -#endif - @end #endif diff --git a/Example/FLEXample/AppDelegate.swift b/Example/FLEXample/AppDelegate.swift index 7b52683226..40378a3a1f 100644 --- a/Example/FLEXample/AppDelegate.swift +++ b/Example/FLEXample/AppDelegate.swift @@ -77,12 +77,6 @@ class AppDelegate: UIResponder, UIApplicationDelegate { ).write(to: URL(fileURLWithPath: whereToSaveBob), options: []) } - #if targetEnvironment(macCatalyst) || arch(arm64) - override var keyCommands: [UIKeyCommand]? { - return FLEXManager.shared.getKeyCommands() - } - #endif - let exampleLogLimit = 10 var exampleLogSent = 0 }