diff options
| author | nyamatongwe <unknown> | 2000-03-25 02:47:21 +0000 | 
|---|---|---|
| committer | nyamatongwe <unknown> | 2000-03-25 02:47:21 +0000 | 
| commit | a578f4a61b6565b2c69c57e9ccaad34e58a95edd (patch) | |
| tree | b549f94202f91f7640852b74839a376f1b13562d /src | |
| parent | 0cfe7678d24a80c28336c539040615f269b4b98d (diff) | |
| download | scintilla-mirror-a578f4a61b6565b2c69c57e9ccaad34e58a95edd.tar.gz | |
FIxed problem with first modification sometimes not looking dirty.
Remonved unused 'PUNTUATION' lexclass.
Diffstat (limited to 'src')
| -rw-r--r-- | src/CellBuffer.cxx | 15 | 
1 files changed, 8 insertions, 7 deletions
| diff --git a/src/CellBuffer.cxx b/src/CellBuffer.cxx index 4d667dcf4..b9fe69660 100644 --- a/src/CellBuffer.cxx +++ b/src/CellBuffer.cxx @@ -404,9 +404,9 @@ void UndoHistory::AppendAction(actionType at, int position, char *data, int leng  	Platform::DebugPrintf("%% %d action %d %d %d\n", at, position, lengthData, currentAction);  	Platform::DebugPrintf("^ %d action %d %d\n", actions[currentAction - 1].at,   		actions[currentAction - 1].position, actions[currentAction - 1].lenData); -	if (0 == undoSequenceDepth) { +	if (currentAction >= 1) { +		if (0 == undoSequenceDepth) {  		// Top level actions may not always be coalesced -		if (currentAction >= 2) {  			Action &actPrevious = actions[currentAction - 1];  			// See if current action can be coalesced into previous action  			// Will work if both are inserts or deletes and position is same @@ -427,13 +427,13 @@ void UndoHistory::AppendAction(actionType at, int position, char *data, int leng  			}  		} else {  			currentAction++; -		} +		}  +	} else { +		currentAction++;  	}  	actions[currentAction].Create(at, position, data, lengthData); -	//if ((collectingUndo == undoCollectAutoStart) && (0 == undoSequenceDepth)) { -		currentAction++; -		actions[currentAction].Create(startAction); -	//} +	currentAction++; +	actions[currentAction].Create(startAction);  	maxAction = currentAction;  } @@ -470,6 +470,7 @@ void UndoHistory::DeleteUndoHistory() {  		actions[i].Destroy();  	maxAction = 0;  	currentAction = 0; +	actions[currentAction].Create(startAction);  	savePoint = 0;  } | 
