# HG changeset patch
# User Chris Cannam
# Date 1553175210 0
# Node ID b234d4d011dff9f6be0ff00cc6be270dc8c59ab2
# Parent  8bf3a52a16042c691cd9887ef650fe4764c0d138
We do need haveTextLabels; restore it

diff -r 8bf3a52a1604 -r b234d4d011df data/model/SparseOneDimensionalModel.h
--- a/data/model/SparseOneDimensionalModel.h	Thu Mar 21 11:35:30 2019 +0000
+++ b/data/model/SparseOneDimensionalModel.h	Thu Mar 21 13:33:30 2019 +0000
@@ -47,6 +47,7 @@
                               bool notifyOnAdd = true) :
         m_sampleRate(sampleRate),
         m_resolution(resolution),
+        m_haveTextLabels(false),
         m_notifier(this,
                    notifyOnAdd ?
                    DeferredNotifier::NOTIFY_ALWAYS :
@@ -79,6 +80,8 @@
     bool canPlay() const override { return true; }
     QString getDefaultPlayClipId() const override { return "tap"; }
     
+    bool hasTextLabels() const { return m_haveTextLabels; }
+    
     int getCompletion() const { return m_completion; }
 
     void setCompletion(int completion, bool update = true) {
@@ -148,6 +151,10 @@
 
         {   QMutexLocker locker(&m_mutex);
             m_events.add(e.withoutValue().withoutDuration());
+
+            if (e.getLabel() != "") {
+                m_haveTextLabels = true;
+            }
         }
         
         m_notifier.update(e.getFrame(), m_resolution);
@@ -290,6 +297,7 @@
     sv_samplerate_t m_sampleRate;
     int m_resolution;
 
+    bool m_haveTextLabels;
     DeferredNotifier m_notifier;
     int m_completion;