Don't double-localize menu shortcuts (#20623)
Release Notes: - Don't have macOS localize our menu shortcuts that we already localized.
This commit is contained in:
parent
3c2dcf50fa
commit
6e477bbf56
1 changed files with 3 additions and 1 deletions
|
@ -19,7 +19,7 @@ use cocoa::{
|
||||||
NSPasteboardTypePNG, NSPasteboardTypeRTF, NSPasteboardTypeRTFD, NSPasteboardTypeString,
|
NSPasteboardTypePNG, NSPasteboardTypeRTF, NSPasteboardTypeRTFD, NSPasteboardTypeString,
|
||||||
NSPasteboardTypeTIFF, NSSavePanel, NSWindow,
|
NSPasteboardTypeTIFF, NSSavePanel, NSWindow,
|
||||||
},
|
},
|
||||||
base::{id, nil, selector, BOOL, YES},
|
base::{id, nil, selector, BOOL, NO, YES},
|
||||||
foundation::{
|
foundation::{
|
||||||
NSArray, NSAutoreleasePool, NSBundle, NSData, NSInteger, NSProcessInfo, NSRange, NSString,
|
NSArray, NSAutoreleasePool, NSBundle, NSData, NSInteger, NSProcessInfo, NSRange, NSString,
|
||||||
NSUInteger, NSURL,
|
NSUInteger, NSURL,
|
||||||
|
@ -343,6 +343,8 @@ impl MacPlatform {
|
||||||
ns_string(key_to_native(&keystroke.key).as_ref()),
|
ns_string(key_to_native(&keystroke.key).as_ref()),
|
||||||
)
|
)
|
||||||
.autorelease();
|
.autorelease();
|
||||||
|
let _: () =
|
||||||
|
msg_send![item, setAllowsAutomaticKeyEquivalentLocalization: NO];
|
||||||
item.setKeyEquivalentModifierMask_(mask);
|
item.setKeyEquivalentModifierMask_(mask);
|
||||||
}
|
}
|
||||||
// For multi-keystroke bindings, render the keystroke as part of the title.
|
// For multi-keystroke bindings, render the keystroke as part of the title.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue