When my WKInterfaceController
poped up by pressing a menuItem (which was settup by "self.addMenuItem
in mainScreen"), the title on the poped WKInterfaceController shows "abbrechen
" instead of "Cancel
". Anyone know how to fix it to make it showing "Cancel
"? Or like where did I probably make a mistake?
//MainScreen.swift
func setContextItems(directToEnabled: Bool) {
self.clearAllMenuItems()
self.addMenuItem(with: WKMenuItemIcon.decline, title: "direct", action: #selector(MainScreen.freePressed))
}
Clues:
TARGET_OS_IOS || TARGET_IPHONE_SIMULATOR
)", but there's nothing related.I guess I might change a plist somewhere that change the locale/laguage only on the Apple Watch. Or maybe it's a rare WatchOS bug. Anyone saw similar problem before ?
Check if you are overriding the language settings when installing over Xcode. This can be done using the scheme editor in Xcode:
Application Language
settingMore information on Testing Specific Languages and Regions (@developer.apple.com)
I am a bit confused by you code? You are giving it the title 'direct' but expecting a title of 'Cancel'?
Should you not be doing:
self.clearAllMenuItems()
self.addMenuItem(withImageNamed: "imageFileForDirectButton", title: "Direct", action: #selector(TheController.menuDirectButtonPressedFunction))
self.addMenuItem(with: WKMenuItemIcon.decline, title: "Cancel", action: #selector(TheController.menuCancelButtonPressedFunction))
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With