diff options
author | nyamatongwe <unknown> | 2001-09-07 08:00:33 +0000 |
---|---|---|
committer | nyamatongwe <unknown> | 2001-09-07 08:00:33 +0000 |
commit | 30f4bacfe06eb177307585e54398a8ac7288448b (patch) | |
tree | 630d8feed1058b3b09e6111387fefdfe9298b2d6 /src | |
parent | a88e392a22aaf99415bf44bf9c09e05574938101 (diff) | |
download | scintilla-mirror-30f4bacfe06eb177307585e54398a8ac7288448b.tar.gz |
Deleting 0 characters has no effect - no notification or undo action.
This prevents SetLineIndentation from often requiring three steps to undo.
Diffstat (limited to 'src')
-rw-r--r-- | src/Document.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Document.cxx b/src/Document.cxx index 10403242b..abbb87d5d 100644 --- a/src/Document.cxx +++ b/src/Document.cxx @@ -357,8 +357,10 @@ void Document::ModifiedAt(int pos) { // Unlike Undo, Redo, and InsertStyledString, the pos argument is a cell number not a char number void Document::DeleteChars(int pos, int len) { + if (len == 0) + return; if ((pos + len) > Length()) - return ; + return; if (cb.IsReadOnly() && enteredReadOnlyCount == 0) { enteredReadOnlyCount++; NotifyModifyAttempt(); |