https://git.reactos.org/?p=reactos.git;a=commitdiff;h=3579ea78889b664b3b977f5d0a725cabf7f92109
commit 3579ea78889b664b3b977f5d0a725cabf7f92109 Author: Katayama Hirofumi MZ <katayama.hirofumi...@gmail.com> AuthorDate: Thu Oct 5 19:51:36 2023 +0900 Commit: GitHub <nore...@github.com> CommitDate: Thu Oct 5 19:51:36 2023 +0900 [MSPAINT] Fix assertion failure on text tool (#5762) Kill the assertion failure on choosing text tool. Check whether textEditWindow is not null by using IsWindowVisible. CORE-19094 --- base/applications/mspaint/mouse.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/base/applications/mspaint/mouse.cpp b/base/applications/mspaint/mouse.cpp index 793efedf3ec..8412cc027c0 100644 --- a/base/applications/mspaint/mouse.cpp +++ b/base/applications/mspaint/mouse.cpp @@ -762,7 +762,8 @@ struct TextTool : ToolBase void OnFinishDraw() override { - if (textEditWindow.GetWindowTextLength() > 0) + if (::IsWindowVisible(textEditWindow) && + textEditWindow.GetWindowTextLength() > 0) { imageModel.PushImageForUndo(); draw(m_hdc);