diff align/Aligner.h @ 761:6429a164b7e1 pitch-align

Schedule alignments with a small delay to avoid too much UI unresponsiveness. Also overhaul error reporting to use signals throughout.
author Chris Cannam
date Wed, 06 May 2020 11:45:27 +0100
parents 31289e8592c7
children a316cb6fed81
line wrap: on
line diff
--- a/align/Aligner.h	Mon Apr 27 14:59:56 2020 +0100
+++ b/align/Aligner.h	Wed May 06 11:45:27 2020 +0100
@@ -26,7 +26,8 @@
 public:
     virtual ~Aligner() { }
 
-    virtual bool begin(QString &error) = 0;
+public slots:
+    virtual void begin() = 0;
 
 signals:
     /**
@@ -34,6 +35,11 @@
      * and toAlign models can be queried from the alignment model.
      */
     void complete(ModelId alignmentModel); // an AlignmentModel
+
+    /**
+     * Emitted when alignment fails.
+     */
+    void failed(ModelId toAlign, QString errorText); // the toAlign model
 };
 
 #endif