SynEdit: fixed group-undo. Group-Undo would prevent the editor from being marked as "changed" in some cases if editing was continued after saving.

git-svn-id: trunk@19102 -
This commit is contained in:
martin 2009-03-25 20:41:06 +00:00
parent 9acc18a2ba
commit c612f1e4e1

View File

@ -706,7 +706,7 @@ begin
if (not FUndoGroup.Items[FUndoGroup.Count - 1].IsCaretInfo)
and assigned(FOnNeedCaretUndo) then
FUndoGroup.Add(FOnNeedCaretUndo());
if (fItems.Count > 0) and FGroupUndo and
if (fItems.Count > 0) and FGroupUndo and (not IsTopMarkedAsUnmodified) and
FUndoGroup.CanMergeWith(TSynEditUndoGroup(fItems[fItems.Count - 1])) then
begin
FUndoGroup.MergeWith(TSynEditUndoGroup(fItems[fItems.Count - 1]));