Mercurial > hg > svcore
diff data/model/AlignmentModel.cpp @ 1688:901f37d32060
Model deletion issues - the AlignmentModel doesn't actually need to know about the input aggregate model; the document should own it instead
author | Chris Cannam |
---|---|
date | Thu, 04 Apr 2019 11:15:43 +0100 |
parents | 70e172e6cc59 |
children | d08b560102a1 |
line wrap: on
line diff
--- a/data/model/AlignmentModel.cpp Wed Feb 27 12:31:12 2019 +0000 +++ b/data/model/AlignmentModel.cpp Thu Apr 04 11:15:43 2019 +0100 @@ -21,11 +21,9 @@ AlignmentModel::AlignmentModel(Model *reference, Model *aligned, - Model *inputModel, SparseTimeValueModel *path) : m_reference(reference), m_aligned(aligned), - m_inputModel(inputModel), m_rawPath(path), m_path(nullptr), m_reversePath(nullptr), @@ -54,9 +52,6 @@ AlignmentModel::~AlignmentModel() { - if (m_inputModel) m_inputModel->aboutToDelete(); - delete m_inputModel; - if (m_rawPath) m_rawPath->aboutToDelete(); delete m_rawPath; @@ -212,9 +207,6 @@ constructPath(); constructReversePath(); - if (m_inputModel) m_inputModel->aboutToDelete(); - delete m_inputModel; - m_inputModel = nullptr; } }