-
-
Notifications
You must be signed in to change notification settings - Fork 108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(mac): both option keys generate right alt if no left alt mapping #12458
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This LGTM, aside from concerns on memory management. Good work
@@ -67,6 +64,38 @@ -(void)changeKeyboardWithKmxFilePath:(NSString*) path { | |||
} | |||
} | |||
|
|||
-(CoreKeyboardInfo*) getKeyboardInfoForKmxFile:(NSString*)kmxFile { | |||
NSArray *keyArray = [self getKeyArray]; | |||
CoreKeyboardInfo* info = [[CoreKeyboardInfo alloc] init:kmxFile keyArray: keyArray]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is keyArray and its members leaked here?
NSMutableArray *keyArray = [[NSMutableArray alloc] initWithCapacity:0]; | ||
km_core_keyboard_key *keyList; | ||
|
||
km_core_status result = km_core_keyboard_get_key_list(self.coreKeyboard, &keyList); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is keyList leaked here?
Test ResultsI tested this issue with the attached "Keyman 18.0.118-alpha-local" build on the macOS Sonoma 14.5 version. here, I am sharing my observation.
It works well. Thank you. |
When a keyman keyboard does not define any rules for the Left Alt key, then both the left and right option keys on the Mac keyboard should result in a Right Alt key combination being generated.
Fixes: #875
Fixes: #933
User Testing