diff options
author | rider <rider@lindenlab.com> | 2015-12-03 13:32:06 -0800 |
---|---|---|
committer | rider <rider@lindenlab.com> | 2015-12-03 13:32:06 -0800 |
commit | eb484d5051c48e3bd35a2f06915eb75cf5c8c1fc (patch) | |
tree | e9f6e43481b8c3ca0bc04a0787d116e277a6a156 /indra/llwindow/llwindowmacosx.cpp | |
parent | 43b7928c680ec5803d793a4f27ece21b6992b590 (diff) |
MAINT-5909: Enable unicode text input on mac and feed that directly into the viewer. Windows fixes still required.
Diffstat (limited to 'indra/llwindow/llwindowmacosx.cpp')
-rwxr-xr-x | indra/llwindow/llwindowmacosx.cpp | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/indra/llwindow/llwindowmacosx.cpp b/indra/llwindow/llwindowmacosx.cpp index 952c6751db..0d41884462 100755 --- a/indra/llwindow/llwindowmacosx.cpp +++ b/indra/llwindow/llwindowmacosx.cpp @@ -221,7 +221,23 @@ void callResetKeys() bool callUnicodeCallback(wchar_t character, unsigned int mask) { - return gWindowImplementation->getCallbacks()->handleUnicodeChar(character, mask); + NativeKeyEventData eventData; + + memset(&eventData, 0, sizeof(NativeKeyEventData)); + + eventData.mKeyEvent = NativeKeyEventData::KEYCHAR; + eventData.mEventType = 0; + eventData.mEventModifiers = mask; + eventData.mEventKeyCode = 0; + eventData.mEventChars = character; + eventData.mEventUnmodChars = character; + eventData.mEventRepeat = false; + + mRawKeyEvent = &eventData; + + bool result = gWindowImplementation->getCallbacks()->handleUnicodeChar(character, mask); + mRawKeyEvent = NULL; + return result; } void callFocus() |