Mercurial > hg > svcore
comparison data/model/TextModel.h @ 1674:69ab62d378bf osc-script
Ensure image & text models get the proper attribute names (which are not the same as the default event ones)
author | Chris Cannam |
---|---|
date | Wed, 27 Mar 2019 16:06:35 +0000 |
parents | 82d03c9661f9 |
children | f97d64b8674f |
comparison
equal
deleted
inserted
replaced
1673:dfcd05e8bd2f | 1674:69ab62d378bf |
---|---|
135 * Editing methods. | 135 * Editing methods. |
136 */ | 136 */ |
137 void add(Event e) override { | 137 void add(Event e) override { |
138 | 138 |
139 { QMutexLocker locker(&m_mutex); | 139 { QMutexLocker locker(&m_mutex); |
140 m_events.add(e.withoutDuration()); | 140 m_events.add(e.withoutDuration().withoutLevel()); |
141 } | 141 } |
142 | 142 |
143 m_notifier.update(e.getFrame(), m_resolution); | 143 m_notifier.update(e.getFrame(), m_resolution); |
144 } | 144 } |
145 | 145 |
248 .arg(m_resolution) | 248 .arg(m_resolution) |
249 .arg("true") // always true after model reaches 100% - | 249 .arg("true") // always true after model reaches 100% - |
250 // subsequent events are always notified | 250 // subsequent events are always notified |
251 .arg(getObjectExportId(&m_events)) | 251 .arg(getObjectExportId(&m_events)) |
252 .arg(extraAttributes)); | 252 .arg(extraAttributes)); |
253 | 253 |
254 m_events.toXml(out, indent, QString("dimensions=\"2\"")); | 254 Event::ExportNameOptions options; |
255 options.valueAtttributeName = "height"; | |
256 | |
257 m_events.toXml(out, indent, QString("dimensions=\"2\""), options); | |
255 } | 258 } |
256 | 259 |
257 protected: | 260 protected: |
258 sv_samplerate_t m_sampleRate; | 261 sv_samplerate_t m_sampleRate; |
259 int m_resolution; | 262 int m_resolution; |