aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authornyamatongwe <unknown>2002-05-07 05:52:15 +0000
committernyamatongwe <unknown>2002-05-07 05:52:15 +0000
commit65be717f3e056ba274b1be196a2ad7b75eaaa58d (patch)
tree69129cf5ae6621418877333d8d7fd5df185bb2e6 /src
parent6807125f2ba42c9105b7405096edf949ae019789 (diff)
downloadscintilla-mirror-65be717f3e056ba274b1be196a2ad7b75eaaa58d.tar.gz
Clear all does not clear the contractionstate if in read-only mode.
Diffstat (limited to 'src')
-rw-r--r--src/Editor.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx
index fa54c2f72..fbf44883c 100644
--- a/src/Editor.cxx
+++ b/src/Editor.cxx
@@ -2319,7 +2319,9 @@ void Editor::ClearAll() {
if (0 != pdoc->Length()) {
pdoc->DeleteChars(0, pdoc->Length());
}
- cs.Clear();
+ if (!pdoc->IsReadOnly()) {
+ cs.Clear();
+ }
pdoc->EndUndoAction();
anchor = 0;
currentPos = 0;