From a2a72ebd708a0225922d27b0fc7a7eadbd48ad12 Mon Sep 17 00:00:00 2001 From: Beq Date: Mon, 19 Feb 2024 02:25:50 +0000 Subject: [PATCH] BOOL -> bool for sdl2 --- indra/llwindow/llkeyboardsdl2.cpp | 12 ++++++------ indra/llwindow/llkeyboardsdl2.h | 10 +++++----- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/indra/llwindow/llkeyboardsdl2.cpp b/indra/llwindow/llkeyboardsdl2.cpp index 594818869e..163c357105 100644 --- a/indra/llwindow/llkeyboardsdl2.cpp +++ b/indra/llwindow/llkeyboardsdl2.cpp @@ -204,12 +204,12 @@ static U32 adjustNativekeyFromUnhandledMask(const U32 key, const U32 mask) } -BOOL LLKeyboardSDL::handleKeyDown(const U32 key, const U32 mask) +bool LLKeyboardSDL::handleKeyDown(const U32 key, const U32 mask) { U32 adjusted_nativekey; KEY translated_key = 0; U32 translated_mask = MASK_NONE; - BOOL handled = FALSE; + bool handled = false; adjusted_nativekey = adjustNativekeyFromUnhandledMask(key, mask); @@ -224,12 +224,12 @@ BOOL LLKeyboardSDL::handleKeyDown(const U32 key, const U32 mask) } -BOOL LLKeyboardSDL::handleKeyUp(const U32 key, const U32 mask) +bool LLKeyboardSDL::handleKeyUp(const U32 key, const U32 mask) { U32 adjusted_nativekey; KEY translated_key = 0; U32 translated_mask = MASK_NONE; - BOOL handled = FALSE; + bool handled = false; adjusted_nativekey = adjustNativekeyFromUnhandledMask(key, mask); @@ -243,7 +243,7 @@ BOOL LLKeyboardSDL::handleKeyUp(const U32 key, const U32 mask) return handled; } -MASK LLKeyboardSDL::currentMask(BOOL for_mouse_event) +MASK LLKeyboardSDL::currentMask(bool for_mouse_event) { MASK result = MASK_NONE; SDL_Keymod mask = SDL_GetModState(); @@ -292,7 +292,7 @@ void LLKeyboardSDL::scanKeyboard() } -BOOL LLKeyboardSDL::translateNumpadKey( const U32 os_key, KEY *translated_key) +bool LLKeyboardSDL::translateNumpadKey( const U32 os_key, KEY *translated_key) { return translateKey(os_key, translated_key); } diff --git a/indra/llwindow/llkeyboardsdl2.h b/indra/llwindow/llkeyboardsdl2.h index 01ded5c146..c76e898bc0 100644 --- a/indra/llwindow/llkeyboardsdl2.h +++ b/indra/llwindow/llkeyboardsdl2.h @@ -11,16 +11,16 @@ public: LLKeyboardSDL(); /*virtual*/ ~LLKeyboardSDL() {}; - /*virtual*/ BOOL handleKeyUp(const U32 key, MASK mask); - /*virtual*/ BOOL handleKeyDown(const U32 key, MASK mask); + /*virtual*/ bool handleKeyUp(const U32 key, MASK mask); + /*virtual*/ bool handleKeyDown(const U32 key, MASK mask); /*virtual*/ void resetMaskKeys(); - /*virtual*/ MASK currentMask(BOOL for_mouse_event); + /*virtual*/ MASK currentMask(bool for_mouse_event); /*virtual*/ void scanKeyboard(); protected: MASK updateModifiers(const U32 mask); - void setModifierKeyLevel( KEY key, BOOL new_state ); - BOOL translateNumpadKey( const U32 os_key, KEY *translated_key ); + void setModifierKeyLevel( KEY key, bool new_state ); + bool translateNumpadKey( const U32 os_key, KEY *translated_key ); U16 inverseTranslateNumpadKey(const KEY translated_key); private: std::map mTranslateNumpadMap; // special map for translating OS keys to numpad keys