Skip to content
Snippets Groups Projects
Commit ddaec889 authored by Rye Mutt's avatar Rye Mutt :bread:
Browse files

Fix build errors in macos keyboard code

parent c83a9a46
No related branches found
No related tags found
1 merge request!16Various package rebuilds and updates including movement to zlib-ng and mac support
......@@ -133,8 +133,7 @@ LLKeyboardMacOSX::LLKeyboardMacOSX()
mTranslateKeyMap[0x7e] = KEY_UP;
// Build inverse map
std::map<U32, KEY>::iterator iter;
for (iter = mTranslateKeyMap.begin(); iter != mTranslateKeyMap.end(); iter++)
for (auto iter = mTranslateKeyMap.begin(); iter != mTranslateKeyMap.end(); iter++)
{
mInvTranslateKeyMap[iter->second] = iter->first;
}
......@@ -154,7 +153,7 @@ LLKeyboardMacOSX::LLKeyboardMacOSX()
mTranslateNumpadMap[0x4c] = KEY_PAD_RETURN; // keypad enter
// Build inverse numpad map
for (iter = mTranslateNumpadMap.begin(); iter != mTranslateNumpadMap.end(); iter++)
for (auto iter = mTranslateNumpadMap.begin(); iter != mTranslateNumpadMap.end(); iter++)
{
mInvTranslateNumpadMap[iter->second] = iter->first;
}
......@@ -279,7 +278,7 @@ MASK LLKeyboardMacOSX::currentMask(BOOL for_mouse_event)
void LLKeyboardMacOSX::scanKeyboard()
{
S32 key;
U32 key;
for (key = 0; key < KEY_COUNT; key++)
{
// Generate callback if any event has occurred on this key this frame.
......
......@@ -126,8 +126,8 @@ void setupInputWindow(NSWindowRef window, GLViewRef view);
// These are all implemented in llwindowmacosx.cpp.
// This is largely for easier interop between Obj-C and C++ (at least in the viewer's case due to the BOOL vs. BOOL conflict)
bool callKeyUp(NSKeyEventRef event, unsigned short key, unsigned int mask);
bool callKeyDown(NSKeyEventRef event, unsigned short key, unsigned int mask);
bool callKeyUp(NSKeyEventRef event, unsigned int key, unsigned int mask);
bool callKeyDown(NSKeyEventRef event, unsigned int key, unsigned int mask);
void callResetKeys();
bool callUnicodeCallback(wchar_t character, unsigned int mask);
void callRightMouseDown(float *pos, unsigned int mask);
......
......@@ -197,7 +197,7 @@ LLWindowMacOSX::LLWindowMacOSX(LLWindowCallbacks* callbacks,
// These functions are used as wrappers for our internal event handling callbacks.
// It's a good idea to wrap these to avoid reworking more code than we need to within LLWindow.
bool callKeyUp(NSKeyEventRef event, unsigned short key, unsigned int mask)
bool callKeyUp(NSKeyEventRef event, unsigned int key, unsigned int mask)
{
mRawKeyEvent = event;
bool retVal = gKeyboard->handleKeyUp(key, mask);
......@@ -205,7 +205,7 @@ bool callKeyUp(NSKeyEventRef event, unsigned short key, unsigned int mask)
return retVal;
}
bool callKeyDown(NSKeyEventRef event, unsigned short key, unsigned int mask)
bool callKeyDown(NSKeyEventRef event, unsigned int key, unsigned int mask)
{
mRawKeyEvent = event;
bool retVal = gKeyboard->handleKeyDown(key, mask);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment