]> sigrok.org Git - pulseview.git/blobdiff - pv/storesession.h
Reimplement file save using the srzip output module.
[pulseview.git] / pv / storesession.h
index 262eddc1eff3a9ad92afef0d673aa85bcb94d5f2..d365730e5217adc3cb352a30770cc346884d8136 100644 (file)
 
 #include <QObject>
 
+namespace sigrok {
+class Output;
+}
+
 namespace pv {
 
 class SigSession;
@@ -51,7 +55,7 @@ public:
 
        ~StoreSession();
 
-       std::pair<uint64_t, uint64_t> progress() const;
+       std::pair<int, int> progress() const;
 
        const QString& error() const;
 
@@ -64,18 +68,20 @@ public:
 private:
        void store_proc(std::shared_ptr<pv::data::LogicSnapshot> snapshot);
 
-signals:
+Q_SIGNALS:
        void progress_updated();
 
 private:
        const std::string _file_name;
        const SigSession &_session;
 
+       std::shared_ptr<sigrok::Output> _output;
+
        std::thread _thread;
 
        std::atomic<bool> _interrupt;
 
-       std::atomic<uint64_t> _units_stored, _unit_count;
+       std::atomic<int> _units_stored, _unit_count;
 
        mutable std::mutex _mutex;
        QString _error;