summaryrefslogtreecommitdiffstats
path: root/tools/platform
diff options
context:
space:
mode:
authorjsmall-nvidia <jsmall@nvidia.com>2023-04-25 10:43:29 -0400
committerGitHub <noreply@github.com>2023-04-25 10:43:29 -0400
commit7b7c095b37e85ca3a8f55eff1c3d9643d467b8e0 (patch)
tree9c71955dbc956b0058b19818ca127c8132cda512 /tools/platform
parent284cee1f246c072f190c87c8fb60c1d2181e458f (diff)
Dictionary using lowerCamel (#2835)
* #include an absolute path didn't work - because paths were taken to always be relative. * WIP lowerCamel Dictionary. * WIP more lowerCamel fixes for Dictionary. * Add/Remove/Clear * GetValue/Contains * Fix tabs in dictionary. Count -> getCount * Fix fields with caps. * Key -> key Value -> value Use m_ for members where appropriate. Use lowerCamel in linked list. * Some small fixes/improvements to Dictionary. * Kick CI.
Diffstat (limited to 'tools/platform')
-rw-r--r--tools/platform/linux/x11-key-code.cpp2
-rw-r--r--tools/platform/linux/x11-window.cpp22
-rw-r--r--tools/platform/windows/win-window.cpp4
3 files changed, 14 insertions, 14 deletions
diff --git a/tools/platform/linux/x11-key-code.cpp b/tools/platform/linux/x11-key-code.cpp
index ce4e8945c..c078a6d1c 100644
--- a/tools/platform/linux/x11-key-code.cpp
+++ b/tools/platform/linux/x11-key-code.cpp
@@ -124,7 +124,7 @@ namespace platform
KeyCode translateKeyCode(int keyCode)
{
KeyCode result = KeyCode::None;
- keyCodeMap.TryGetValue(keyCode, result);
+ keyCodeMap.tryGetValue(keyCode, result);
return result;
}
diff --git a/tools/platform/linux/x11-window.cpp b/tools/platform/linux/x11-window.cpp
index 2721c00f3..be807ac33 100644
--- a/tools/platform/linux/x11-window.cpp
+++ b/tools/platform/linux/x11-window.cpp
@@ -179,7 +179,7 @@ public:
{
if (handle)
{
- X11AppContext::windows.Remove(handle);
+ X11AppContext::windows.remove(handle);
XDestroyWindow(X11AppContext::xdisplay, handle);
handle = 0;
}
@@ -382,7 +382,7 @@ void doEventsImpl(bool waitForEvents)
else if (X11AppContext::keyStates[iKeyCode] == KeyState::Pressed)
X11AppContext::keyStates[iKeyCode] = KeyState::Hold;
}
- if (X11AppContext::windows.TryGetValue(nextEvent.xkey.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xkey.window, sysWindow))
{
wchar_t keyChar = getKeyChar(vKeyCode, nextEvent.xkey.state);
sysWindow->handleKeyEvent(KeyEvent::Press, vKeyCode, keyChar, nextEvent.xkey.state);
@@ -395,13 +395,13 @@ void doEventsImpl(bool waitForEvents)
{
X11AppContext::keyStates[iKeyCode] = KeyState::Released;
}
- if (X11AppContext::windows.TryGetValue(nextEvent.xkey.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xkey.window, sysWindow))
{
sysWindow->handleKeyEvent(KeyEvent::Release, vKeyCode, 0, nextEvent.xkey.state);
}
break;
case MotionNotify:
- if (X11AppContext::windows.TryGetValue(nextEvent.xmotion.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xmotion.window, sysWindow))
{
X11AppContext::currentMouseEventWindow = sysWindow;
sysWindow->handleMouseEvent(MouseEvent::Move, nextEvent.xmotion.x, nextEvent.xmotion.y, 0,
@@ -409,7 +409,7 @@ void doEventsImpl(bool waitForEvents)
}
break;
case ButtonPress:
- if (X11AppContext::windows.TryGetValue(nextEvent.xbutton.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xbutton.window, sysWindow))
{
X11AppContext::currentMouseEventWindow = sysWindow;
if (nextEvent.xbutton.button <= Button3)
@@ -424,7 +424,7 @@ void doEventsImpl(bool waitForEvents)
}
break;
case ButtonRelease:
- if (X11AppContext::windows.TryGetValue(nextEvent.xbutton.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xbutton.window, sysWindow))
{
X11AppContext::currentMouseEventWindow = sysWindow;
sysWindow->handleMouseEvent(MouseEvent::Up, nextEvent.xbutton.x, nextEvent.xbutton.y, 0,
@@ -432,19 +432,19 @@ void doEventsImpl(bool waitForEvents)
}
break;
case ConfigureNotify:
- if (X11AppContext::windows.TryGetValue(nextEvent.xconfigure.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xconfigure.window, sysWindow))
{
sysWindow->handleResizeEvent(nextEvent.xconfigure.width, nextEvent.xconfigure.height);
}
break;
case Expose:
- if (X11AppContext::windows.TryGetValue(nextEvent.xexpose.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xexpose.window, sysWindow))
{
sysWindow->handleExposeEvent();
}
break;
case ClientMessage:
- if (X11AppContext::windows.TryGetValue(nextEvent.xclient.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xclient.window, sysWindow))
{
Atom wmDelete = XInternAtom(X11AppContext::xdisplay, "WM_DELETE_WINDOW", True);
if (nextEvent.xclient.data.l[0] == wmDelete)
@@ -454,13 +454,13 @@ void doEventsImpl(bool waitForEvents)
}
break;
case FocusIn:
- if (X11AppContext::windows.TryGetValue(nextEvent.xfocus.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xfocus.window, sysWindow))
{
sysWindow->handleFocus(true);
}
break;
case FocusOut:
- if (X11AppContext::windows.TryGetValue(nextEvent.xfocus.window, sysWindow))
+ if (X11AppContext::windows.tryGetValue(nextEvent.xfocus.window, sysWindow))
{
sysWindow->handleFocus(false);
}
diff --git a/tools/platform/windows/win-window.cpp b/tools/platform/windows/win-window.cpp
index d785b0fb7..896bbd2c6 100644
--- a/tools/platform/windows/win-window.cpp
+++ b/tools/platform/windows/win-window.cpp
@@ -71,7 +71,7 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
bool useDefProc = true;
Window* window = nullptr;
- Win32AppContext::windows.TryGetValue(hWnd, window);
+ Win32AppContext::windows.tryGetValue(hWnd, window);
switch (message)
{
case WM_LBUTTONUP:
@@ -400,7 +400,7 @@ public:
{
if (handle)
{
- Win32AppContext::windows.Remove(handle);
+ Win32AppContext::windows.remove(handle);
}
DestroyWindow(handle);
handle = NULL;