diff options
Diffstat (limited to 'qdeduper/filescanner.hpp')
-rw-r--r-- | qdeduper/filescanner.hpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/qdeduper/filescanner.hpp b/qdeduper/filescanner.hpp index 5d927a4..3df620e 100644 --- a/qdeduper/filescanner.hpp +++ b/qdeduper/filescanner.hpp @@ -1,6 +1,7 @@ #ifndef FILESCANNER_HPP #define FILESCANNER_HPP +#include <atomic> #include <filesystem> #include <string> #include <utility> @@ -16,11 +17,14 @@ class FileScanner : public QObject std::vector<std::pair<fs::path, bool>> paths; std::vector<fs::path> ret; std::size_t maxmnlen; + std::atomic<bool> interrpt; public: FileScanner(); void add_magic_number(const std::string &m); void add_path(const fs::path &p, bool recurse = false); void scan(); + void interrupt(); + bool interrupted(); std::vector<fs::path> file_list(); Q_SIGNALS: void scan_done_prep(std::size_t nfiles); |