mirror of
https://github.com/rizonesoft/Notepad3.git
synced 2026-06-14 21:09:05 +08:00
+ fix: consecutive DEL/BACKSP undo/redo broken (wrapped by unconditional selection undo/redo)
This commit is contained in:
parent
727b650de0
commit
c1a568400a
@ -4519,7 +4519,9 @@ LRESULT MsgCommand(HWND hwnd,WPARAM wParam,LPARAM lParam)
|
||||
|
||||
|
||||
case CMD_DEL:
|
||||
{
|
||||
if ((BOOL)SendMessage(hwndEdit, SCI_GETSELECTIONEMPTY, 0, 0))
|
||||
SendMessage(hwndEdit, SCI_CLEAR, 0, 0);
|
||||
else {
|
||||
int token = BeginSelUndoAction();
|
||||
SendMessage(hwndEdit, SCI_CLEAR, 0, 0);
|
||||
EndSelUndoAction(token);
|
||||
@ -4528,7 +4530,9 @@ LRESULT MsgCommand(HWND hwnd,WPARAM wParam,LPARAM lParam)
|
||||
|
||||
|
||||
case CMD_BACK:
|
||||
{
|
||||
if ((BOOL)SendMessage(hwndEdit, SCI_GETSELECTIONEMPTY, 0, 0))
|
||||
SendMessage(hwndEdit, SCI_DELETEBACK, 0, 0);
|
||||
else {
|
||||
int token = BeginSelUndoAction();
|
||||
SendMessage(hwndEdit, SCI_DELETEBACK, 0, 0);
|
||||
EndSelUndoAction(token);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user