Mercurial > hg > svcore
comparison data/model/ImageModel.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 | a77a7e8c085c |
children | f97d64b8674f |
comparison
equal
deleted
inserted
replaced
1673:dfcd05e8bd2f | 1674:69ab62d378bf |
---|---|
140 * Editing methods. | 140 * Editing methods. |
141 */ | 141 */ |
142 void add(Event e) override { | 142 void add(Event e) override { |
143 | 143 |
144 { QMutexLocker locker(&m_mutex); | 144 { QMutexLocker locker(&m_mutex); |
145 m_events.add(e.withoutDuration()); | 145 m_events.add(e.withoutDuration().withoutValue().withoutLevel()); |
146 } | 146 } |
147 | 147 |
148 m_notifier.update(e.getFrame(), m_resolution); | 148 m_notifier.update(e.getFrame(), m_resolution); |
149 } | 149 } |
150 | 150 |
253 .arg(m_resolution) | 253 .arg(m_resolution) |
254 .arg("true") // always true after model reaches 100% - | 254 .arg("true") // always true after model reaches 100% - |
255 // subsequent events are always notified | 255 // subsequent events are always notified |
256 .arg(getObjectExportId(&m_events)) | 256 .arg(getObjectExportId(&m_events)) |
257 .arg(extraAttributes)); | 257 .arg(extraAttributes)); |
258 | 258 |
259 m_events.toXml(out, indent, QString("dimensions=\"1\"")); | 259 Event::ExportNameOptions options; |
260 options.uriAttributeName = "image"; | |
261 | |
262 m_events.toXml(out, indent, QString("dimensions=\"1\""), options); | |
260 } | 263 } |
261 | 264 |
262 protected: | 265 protected: |
263 sv_samplerate_t m_sampleRate; | 266 sv_samplerate_t m_sampleRate; |
264 int m_resolution; | 267 int m_resolution; |