[escher] Palette: factorize data color iteration

This commit is contained in:
Émilie Feral
2020-03-23 18:16:29 +01:00
parent c4847b22cc
commit 886fc98350
9 changed files with 26 additions and 7 deletions

View File

@@ -31,6 +31,7 @@ Ion::Storage::Record::ErrorStatus SequenceStore::addEmptyModel() {
const char * name = firstAvailableName(&nameIndex);
assert(name);
// Choose the corresponding color
assert(nameIndex < Palette::numberOfDataColors());
KDColor color = Palette::DataColor[nameIndex];
Sequence::RecordDataBuffer data(color);
// m_sequences