changeset 1548:51d6551d5244

Show default name for unlabelled bin
author Chris Cannam
date Wed, 03 Oct 2018 15:45:57 +0100
parents 9c14dee72329
children 2fec0d9bd7ac 4de4284d0596
files data/model/DenseThreeDimensionalModel.h
diffstat 1 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/data/model/DenseThreeDimensionalModel.h	Mon Oct 01 14:37:30 2018 +0100
+++ b/data/model/DenseThreeDimensionalModel.h	Wed Oct 03 15:45:57 2018 +0100
@@ -137,7 +137,12 @@
         switch (column) {
         case 0: return tr("Time");
         case 1: return tr("Frame");
-        default: return getBinName(column - 2);
+        default:
+            QString name = getBinName(column - 2);
+            if (name == "") {
+                name = tr("(bin %1)").arg(column - 2);
+            }
+            return name;
         }
     }