From e97d02a294434d12419fc267cb9c350d752994bd Mon Sep 17 00:00:00 2001 From: ocornut Date: Sat, 14 Mar 2015 10:49:26 +0000 Subject: [PATCH] Examples: Fixed Clang warnings in DirectX examples --- examples/directx11_example/imgui_impl_dx11.cpp | 4 ++-- examples/directx9_example/imgui_impl_dx9.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/directx11_example/imgui_impl_dx11.cpp b/examples/directx11_example/imgui_impl_dx11.cpp index 4e209c87..2502b98d 100644 --- a/examples/directx11_example/imgui_impl_dx11.cpp +++ b/examples/directx11_example/imgui_impl_dx11.cpp @@ -171,11 +171,11 @@ LRESULT ImGui_ImplDX11_WndProcHandler(HWND, UINT msg, WPARAM wParam, LPARAM lPar io.MousePos.y = (signed short)(lParam >> 16); return true; case WM_KEYDOWN: - if (wParam >= 0 && wParam < 256) + if (wParam < 256) io.KeysDown[wParam] = 1; return true; case WM_KEYUP: - if (wParam >= 0 && wParam < 256) + if (wParam < 256) io.KeysDown[wParam] = 0; return true; case WM_CHAR: diff --git a/examples/directx9_example/imgui_impl_dx9.cpp b/examples/directx9_example/imgui_impl_dx9.cpp index f6f2a11a..60302d4c 100644 --- a/examples/directx9_example/imgui_impl_dx9.cpp +++ b/examples/directx9_example/imgui_impl_dx9.cpp @@ -135,11 +135,11 @@ LRESULT ImGui_ImplDX9_WndProcHandler(HWND, UINT msg, WPARAM wParam, LPARAM lPara io.MousePos.y = (signed short)(lParam >> 16); return true; case WM_KEYDOWN: - if (wParam >= 0 && wParam < 256) + if (wParam < 256) io.KeysDown[wParam] = 1; return true; case WM_KEYUP: - if (wParam >= 0 && wParam < 256) + if (wParam < 256) io.KeysDown[wParam] = 0; return true; case WM_CHAR: