From d7c2a9065f05845a7378e77ddc41b63b8dff6d1c Mon Sep 17 00:00:00 2001 From: Erik Verbruggen Date: Wed, 10 Feb 2010 16:07:40 +0100 Subject: Fixed regression. --- src/gui/text/qtextdocument_p.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gui/text/qtextdocument_p.cpp b/src/gui/text/qtextdocument_p.cpp index b36642b..e2fdf0e 100644 --- a/src/gui/text/qtextdocument_p.cpp +++ b/src/gui/text/qtextdocument_p.cpp @@ -260,7 +260,7 @@ void QTextDocumentPrivate::clear() title.clear(); undoState = 0; - clearUndoRedoStacks(QTextDocument::UndoStack); + clearUndoRedoStacks(QTextDocument::RedoStack); text = QString(); unreachableCharacterCount = 0; modifiedState = 0; @@ -292,7 +292,7 @@ QTextDocumentPrivate::~QTextDocumentPrivate() cursors.clear(); undoState = 0; undoEnabled = true; - clearUndoRedoStacks(QTextDocument::UndoStack); + clearUndoRedoStacks(QTextDocument::RedoStack); } void QTextDocumentPrivate::setLayout(QAbstractTextDocumentLayout *layout) @@ -1027,7 +1027,7 @@ void QTextDocumentPrivate::appendUndoItem(const QTextUndoCommand &c) if (!undoEnabled) return; if (undoState < undoStack.size()) - clearUndoRedoStacks(QTextDocument::UndoStack); + clearUndoRedoStacks(QTextDocument::RedoStack); if (!undoStack.isEmpty() && modified) { QTextUndoCommand &last = undoStack[undoState - 1]; @@ -1117,7 +1117,7 @@ void QTextDocumentPrivate::enableUndoRedo(bool enable) if (!enable) { undoState = 0; - clearUndoRedoStacks(QTextDocument::UndoStack); + clearUndoRedoStacks(QTextDocument::RedoStack); emitUndoAvailable(false); emitRedoAvailable(false); } -- cgit v0.12