qt5base-lts/tests/auto/widgets
Addison Elliott 00ad7bd5a4 Added isObsolete and setObsolete functions in QUndoStack
Added isObsolete and setObsolete functions to QUndoCommand that signifies
a command is not functional. This is useful for when two commands are
merged in such a way that the merged command does nothing. Another
particular use is with networking commands in which the command fails
due to connection issues. The command is considered obsolete because the
undo/redo functions do nothing since the connection failed.

This property is checked in QUndoStack::push(), QUndoStack::undo(),
QUndoStack::redo(), and QUndoStack::setIndex(). The obsolete flag is
checked after QUndoCommand::undo(), QUndoCommand::redo(), and
QUndoCommand::mergeWith() is called where applicable. This allows the
user to set the obsolete flag within the QUndoCommand class and it will
be deleted directly afterwards.

Task-number: QTBUG-54970
Change-Id: Ia8e962ff3aa16515e8f9e2180aee5e1d726d5ba3
Reviewed-by: David Faure <david.faure@kdab.com>
2017-01-02 13:31:25 +00:00
..
dialogs tests/auto/widgets: use QCOMPARE(., nullptr) 2016-11-30 07:24:47 +00:00
effects QtWidgets: Remove Windows CE. 2016-04-07 10:24:45 +00:00
gestures autotests: use QTest::createTouchDevice() 2016-06-10 13:07:17 +00:00
graphicsview tests/auto/widgets: use QCOMPARE(., nullptr) 2016-11-30 07:24:47 +00:00
itemviews tests/auto/widgets: use QCOMPARE(., nullptr) 2016-11-30 07:24:47 +00:00
kernel Merge remote-tracking branch 'origin/5.8' into dev 2016-12-13 09:39:20 +01:00
styles tests/auto/widgets: use QCOMPARE(., nullptr) 2016-11-30 07:24:47 +00:00
util Added isObsolete and setObsolete functions in QUndoStack 2017-01-02 13:31:25 +00:00
widgets QSplitterHandle: Ensure a minimum grab area 2016-12-23 19:23:24 +00:00
widgets.pro Add autotest for QGestureRecognizer. 2014-10-23 21:11:28 +02:00