From b8b2a1dd9c4d75d2383118987971f99618da9916 Mon Sep 17 00:00:00 2001 From: scheffle Date: Sat, 23 Mar 2024 13:50:27 +0100 Subject: [PATCH] fix wrong redo --- vstgui/lib/ctexteditor.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/vstgui/lib/ctexteditor.cpp b/vstgui/lib/ctexteditor.cpp index 3fd537ff5..94468b5f4 100644 --- a/vstgui/lib/ctexteditor.cpp +++ b/vstgui/lib/ctexteditor.cpp @@ -2795,8 +2795,7 @@ void TextEditorView::doUndoRedo () const } else if (it->characters.empty () == false) { - md.editState.select_end = - md.editState.select_start + static_cast (it->characters.size ()); + md.editState.select_end = md.editState.select_start; callSTB ([&] () { stb_textedit_paste (this, &md.editState, it->characters.data (), static_cast (it->characters.size ()));