ImGui fixed

- Disabled DpiAwareness
- Now using ImGui implementation  WndProcHandler
- Fixed horizontal scrolling
This commit is contained in:
Simon Lübeß
2020-11-17 17:53:48 +01:00
parent 8d39da3d3d
commit 0237e0b38d
2 changed files with 35 additions and 16 deletions
@@ -218,7 +218,9 @@ namespace GlitchyEngine
{
return DefWindowProcW(hwnd, uMsg, wParam, lParam);
}
ImGui.ImGuiImplWin32.WndProcHandler(hwnd, uMsg, wParam, lParam);
switch (uMsg)
{
////
@@ -371,8 +373,7 @@ namespace GlitchyEngine
// Horizontal scrolling
case WM_MOUSEHWHEEL:
{
// horizontal scrolling is inverted for some reason
int32 rotation = -(int16)HighOrder!((int64)wParam) / WHEEL_DELTA;
int32 rotation = (int16)HighOrder!((int64)wParam) / WHEEL_DELTA;
var event = scope MouseScrolledEvent(rotation, 0);
window._eventCallback(event);