From 0e8efb6225fe6c51b31b6d3e3ee99a6c7df8c3ff Mon Sep 17 00:00:00 2001 From: y5nw <37980625+y5nw@users.noreply.github.com> Date: Wed, 7 Feb 2024 21:45:59 +0100 Subject: [PATCH] Address minor issues --- source/Irrlicht/CIrrDeviceSDL.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/Irrlicht/CIrrDeviceSDL.cpp b/source/Irrlicht/CIrrDeviceSDL.cpp index 37235ed6..7b643ce2 100644 --- a/source/Irrlicht/CIrrDeviceSDL.cpp +++ b/source/Irrlicht/CIrrDeviceSDL.cpp @@ -219,14 +219,14 @@ void CIrrDeviceSDL::resetReceiveTextInputEvents() { gui::IGUIElement *elem = GUIEnvironment->getFocus(); if (elem && elem->acceptsIME()) { - SDL_StartTextInput(); core::rect pos = elem->getAbsolutePosition(); SDL_Rect rect; rect.x = pos.UpperLeftCorner.X; rect.y = pos.UpperLeftCorner.Y; - rect.w = pos.LowerRightCorner.X - rect.x; - rect.h = pos.LowerRightCorner.Y - rect.y; + rect.w = pos.getWidth(); + rect.h = pos.getHeight(); SDL_SetTextInputRect(&rect); + SDL_StartTextInput(); } else {