Doc: Improve the documentation of transactions (#21494)

This commit is contained in:
Pieter Hijma
2025-11-14 19:52:13 +01:00
committed by GitHub
parent 4fd6dc5120
commit 0083364dbe
4 changed files with 231 additions and 70 deletions

View File

@@ -52,10 +52,6 @@ Transaction::Transaction(int id)
transID = id;
}
/**
* A destructor.
* A more elaborate description of the destructor.
*/
Transaction::~Transaction()
{
auto& index = _Objects.get<0>();
@@ -291,16 +287,8 @@ TYPESYSTEM_SOURCE_ABSTRACT(App::TransactionObject, Base::Persistence)
//**************************************************************************
// Construction/Destruction
/**
* A constructor.
* A more elaborate description of the constructor.
*/
TransactionObject::TransactionObject() = default;
/**
* A destructor.
* A more elaborate description of the destructor.
*/
TransactionObject::~TransactionObject()
{
for (auto& v : _PropChangeMap) {
@@ -344,7 +332,7 @@ void TransactionObject::applyChn(Document& /*Doc*/, TransactionalObject* pcObj,
}
// getPropertyName() is specially coded to be safe even if prop has
// been destroies. We must prepare for the case where user removed
// been destroyed. We must prepare for the case where user removed
// a dynamic property but does not recordered as transaction.
auto name = pcObj->getPropertyName(prop);
if (!name || (!data.name.empty() && data.name != name)