FLEXTool/FLEX

Keyboard shortcuts don't work when using UIKit for Mac (Project Catalyst)

Open

#297 opened on Jul 28, 2019

View on GitHub
 (5 comments) (0 reactions) (0 assignees)Objective-C (14,597 stars) (1,777 forks)batch import
help wanted

Description

I successfully added the f shortcut in my app by adding:

- (NSArray<UIKeyCommand *> *)keyCommands {

	UIKeyCommand *flexToggleCommand = [UIKeyCommand keyCommandWithInput:@"f" modifierFlags:kNilOptions action:@selector(onFLEXToggleCommandTrigger)];

	return @[flexToggleCommand];
}

- (void)onFLEXToggleCommandTrigger {

	[[FLEXManager sharedManager] toggleExplorer];
}

in AppDelegate.m, but I don't know how to add all of them directly in FLEX, hence I created an issue instead of a PR.

Contributor guide