Mercurial > hg > svcore
changeset 1701:81f50b70bdef single-point
The editable dense 3d model uses ready/completion status differently from the new implementation it was inheriting from the base class - it is always "ready" even if not yet complete
author | Chris Cannam |
---|---|
date | Tue, 07 May 2019 15:52:12 +0100 |
parents | c1208b211d8c |
children | b17fb3a4560c |
files | data/model/EditableDenseThreeDimensionalModel.cpp data/model/EditableDenseThreeDimensionalModel.h |
diffstat | 2 files changed, 16 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/data/model/EditableDenseThreeDimensionalModel.cpp Fri May 03 15:02:09 2019 +0100 +++ b/data/model/EditableDenseThreeDimensionalModel.cpp Tue May 07 15:52:12 2019 +0100 @@ -57,6 +57,13 @@ return true; } +bool +EditableDenseThreeDimensionalModel::isReady(int *completion) const +{ + if (completion) *completion = getCompletion(); + return true; +} + sv_samplerate_t EditableDenseThreeDimensionalModel::getSampleRate() const { @@ -486,6 +493,12 @@ } } +int +EditableDenseThreeDimensionalModel::getCompletion() const +{ + return m_completion; +} + QString EditableDenseThreeDimensionalModel::toDelimitedDataString(QString delimiter, DataExportOptions,
--- a/data/model/EditableDenseThreeDimensionalModel.h Fri May 03 15:02:09 2019 +0100 +++ b/data/model/EditableDenseThreeDimensionalModel.h Tue May 07 15:52:12 2019 +0100 @@ -49,6 +49,9 @@ bool notifyOnAdd = true); bool isOK() const override; + bool isReady(int *completion = 0) const override; + void setCompletion(int completion, bool update = true); + int getCompletion() const override; sv_samplerate_t getSampleRate() const override; sv_frame_t getStartFrame() const override; @@ -183,9 +186,6 @@ */ bool shouldUseLogValueScale() const override; - virtual void setCompletion(int completion, bool update = true); - int getCompletion() const override { return m_completion; } - QString getTypeName() const override { return tr("Editable Dense 3-D"); } QString toDelimitedDataString(QString delimiter,