summaryrefslogtreecommitdiff
path: root/indra/llwindow/llkeyboardmacosx.cpp
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2024-06-10 20:03:54 +0300
committerGitHub <noreply@github.com>2024-06-10 20:03:54 +0300
commitf74c10c4ec6435471bac84473fe865f90843c2df (patch)
treeb2853d87789dbb84d6c26c259eab6639d3a7e482 /indra/llwindow/llkeyboardmacosx.cpp
parent5fccb539937a52d286274a002266e022e2102e5e (diff)
parent32fcefc058ae38eff0572326ef3efd1c7b343144 (diff)
Merge branch 'DRTVWR-600-maint-A' into signal/trim-trailing
Diffstat (limited to 'indra/llwindow/llkeyboardmacosx.cpp')
-rw-r--r--indra/llwindow/llkeyboardmacosx.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/indra/llwindow/llkeyboardmacosx.cpp b/indra/llwindow/llkeyboardmacosx.cpp
index a1aeb2e5e4..89ff7c6d3f 100644
--- a/indra/llwindow/llkeyboardmacosx.cpp
+++ b/indra/llwindow/llkeyboardmacosx.cpp
@@ -172,22 +172,22 @@ void LLKeyboardMacOSX::resetMaskKeys()
if(mask & MAC_SHIFT_KEY)
{
- mKeyLevel[KEY_SHIFT] = TRUE;
+ mKeyLevel[KEY_SHIFT] = true;
}
if(mask & MAC_CTRL_KEY)
{
- mKeyLevel[KEY_CONTROL] = TRUE;
+ mKeyLevel[KEY_CONTROL] = true;
}
if(mask & MAC_ALT_KEY)
{
- mKeyLevel[KEY_ALT] = TRUE;
+ mKeyLevel[KEY_ALT] = true;
}
}
/*
-static BOOL translateKeyMac(const U16 key, const U32 mask, KEY &outKey, U32 &outMask)
+static bool translateKeyMac(const U16 key, const U32 mask, KEY &outKey, U32 &outMask)
{
// Translate the virtual keycode into the keycodes the keyboard system expects.
U16 virtualKey = (mask >> 24) & 0x0000007F;
@@ -226,11 +226,11 @@ MASK LLKeyboardMacOSX::updateModifiers(const U32 mask)
return out_mask;
}
-BOOL LLKeyboardMacOSX::handleKeyDown(const U16 key, const U32 mask)
+bool LLKeyboardMacOSX::handleKeyDown(const U16 key, const U32 mask)
{
KEY translated_key = 0;
U32 translated_mask = 0;
- BOOL handled = FALSE;
+ bool handled = false;
translated_mask = updateModifiers(mask);
@@ -243,11 +243,11 @@ BOOL LLKeyboardMacOSX::handleKeyDown(const U16 key, const U32 mask)
}
-BOOL LLKeyboardMacOSX::handleKeyUp(const U16 key, const U32 mask)
+bool LLKeyboardMacOSX::handleKeyUp(const U16 key, const U32 mask)
{
KEY translated_key = 0;
U32 translated_mask = 0;
- BOOL handled = FALSE;
+ bool handled = false;
translated_mask = updateModifiers(mask);
@@ -259,7 +259,7 @@ BOOL LLKeyboardMacOSX::handleKeyUp(const U16 key, const U32 mask)
return handled;
}
-MASK LLKeyboardMacOSX::currentMask(BOOL for_mouse_event)
+MASK LLKeyboardMacOSX::currentMask(bool for_mouse_event)
{
MASK result = MASK_NONE;
U32 mask = getModifiers();
@@ -295,8 +295,8 @@ void LLKeyboardMacOSX::scanKeyboard()
// Reset edges for next frame
for (key = 0; key < KEY_COUNT; key++)
{
- mKeyUp[key] = FALSE;
- mKeyDown[key] = FALSE;
+ mKeyUp[key] = false;
+ mKeyDown[key] = false;
if (mKeyLevel[key])
{
mKeyLevelFrameCount[key]++;
@@ -304,7 +304,7 @@ void LLKeyboardMacOSX::scanKeyboard()
}
}
-BOOL LLKeyboardMacOSX::translateNumpadKey( const U16 os_key, KEY *translated_key )
+bool LLKeyboardMacOSX::translateNumpadKey( const U16 os_key, KEY *translated_key )
{
return translateKey(os_key, translated_key);
}