Fix iOS/macOS keycode handling regression for textoverlay example, update and use keycodes.hpp defines for iOS/macOS
This commit is contained in:
parent
8080b7a91b
commit
a1e19ea5de
5 changed files with 43 additions and 49 deletions
|
|
@ -97,13 +97,13 @@ const std::string getAssetPath() {
|
|||
|
||||
// A key on the keyboard has been pressed.
|
||||
-(void) insertText: (NSString*) text {
|
||||
unichar keychar = (text.length > 0) ? [text characterAtIndex: 0] : 0;
|
||||
unichar keychar = (text.length > 0) ? [text.lowercaseString characterAtIndex: 0] : 0;
|
||||
_mvkExample->keyPressed(keychar);
|
||||
}
|
||||
|
||||
// The delete backward key has been pressed.
|
||||
-(void) deleteBackward {
|
||||
_mvkExample->keyPressed(0x7F);
|
||||
_mvkExample->keyPressed(KEY_DELETE);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue