add method to check if an open transaction is empty
This is needed to avoid to incorrectly abort a transaction if a recompute was done between opening and closing an editor in the property view
This commit is contained in:
@@ -1029,6 +1029,15 @@ bool Document::hasPendingTransaction() const
|
||||
return false;
|
||||
}
|
||||
|
||||
bool Document::isTransactionEmpty() const
|
||||
{
|
||||
if (d->activeUndoTransaction) {
|
||||
return d->activeUndoTransaction->isEmpty();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void Document::clearUndos()
|
||||
{
|
||||
if (d->activeUndoTransaction)
|
||||
|
||||
Reference in New Issue
Block a user