Merge pull request #7635 from archimede67/fix-escape-key-lineinput

Fix escape key not working when lineinput is focused
This commit is contained in:
Edgar 2023-12-12 08:14:51 +00:00 committed by GitHub
commit 082c44889a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -842,7 +842,7 @@ bool CUI::DoEditBox(CLineInput *pLineInput, const CUIRect *pRect, float FontSize
pRect->Draw(ms_LightButtonColorFunction.GetColor(Active, HotItem() == pLineInput), Corners, 3.0f);
ClipEnable(pRect);
Textbox.x -= ScrollOffset;
const STextBoundingBox BoundingBox = pLineInput->Render(&Textbox, FontSize, TEXTALIGN_ML, Changed, -1.0f, 0.0f);
const STextBoundingBox BoundingBox = pLineInput->Render(&Textbox, FontSize, TEXTALIGN_ML, pLineInput->WasCursorChanged(), -1.0f, 0.0f);
ClipDisable();
// Scroll left or right if necessary