diff -r daa8770b9d26 -r d862721d19a3 src/model.cpp --- a/src/model.cpp Wed Jun 29 16:21:44 2022 +0300 +++ b/src/model.cpp Wed Jun 29 16:33:49 2022 +0300 @@ -173,10 +173,10 @@ { } -ModelId Model::append(const ModelElement &value) +ElementId Model::append(const ModelElement &value) { const std::size_t position = this->size(); - const ModelId id = this->runningId; + const ElementId id = this->runningId; this->runningId.value += 1; const int row = narrow(signed_cast(this->size())); Q_EMIT this->beginInsertRows({}, row, row); @@ -191,7 +191,7 @@ return this->body[position].data; } -ModelId Model::idAt(std::size_t position) const +ElementId Model::idAt(std::size_t position) const { return this->body[position].id; } @@ -203,7 +203,7 @@ Q_EMIT this->dataChanged(index, index); } -std::optional Model::find(ModelId id) const +std::optional Model::find(ElementId id) const { return pointerToOptional(findInMap(this->positions, id)); }