diff options
author | TheKodeToad <TheKodeToad@proton.me> | 2023-07-22 11:26:02 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-22 11:26:02 +0100 |
commit | 57430fd189aed592a170d597de61b3acabaaa43d (patch) | |
tree | b3727db40fdea31d24541c0c8181c43df13e774c /launcher/FileSystem.h | |
parent | ec85266860b7503b24ff3840fb6bf74588acc7c8 (diff) | |
parent | 6ffcfcd7e9d96ae0a2846d1cf23b27425a838709 (diff) | |
download | PrismLauncher-57430fd189aed592a170d597de61b3acabaaa43d.tar.gz PrismLauncher-57430fd189aed592a170d597de61b3acabaaa43d.tar.bz2 PrismLauncher-57430fd189aed592a170d597de61b3acabaaa43d.zip |
Merge branch 'develop' into better-launch
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
Diffstat (limited to 'launcher/FileSystem.h')
-rw-r--r-- | launcher/FileSystem.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/launcher/FileSystem.h b/launcher/FileSystem.h index cb581d0c..f8a82bae 100644 --- a/launcher/FileSystem.h +++ b/launcher/FileSystem.h @@ -43,6 +43,7 @@ #include <system_error> #include <QDir> +#include <QPair> #include <QFlags> #include <QLocalServer> #include <QObject> @@ -112,9 +113,12 @@ class copy : public QObject { bool operator()(bool dryRun = false) { return operator()(QString(), dryRun); } int totalCopied() { return m_copied; } + int totalFailed() { return m_failedPaths.length(); } + QStringList failed() { return m_failedPaths; } signals: void fileCopied(const QString& relativeName); + void copyFailed(const QString& relativeName); // TODO: maybe add a "shouldCopy" signal in the future? private: @@ -127,6 +131,7 @@ class copy : public QObject { QDir m_src; QDir m_dst; int m_copied; + QStringList m_failedPaths; }; struct LinkPair { @@ -471,6 +476,9 @@ class clone : public QObject { bool operator()(bool dryRun = false) { return operator()(QString(), dryRun); } int totalCloned() { return m_cloned; } + int totalFailed() { return m_failedClones.length(); } + + QList<QPair<QString, QString>> failed() { return m_failedClones; } signals: void fileCloned(const QString& src, const QString& dst); @@ -485,6 +493,7 @@ class clone : public QObject { QDir m_src; QDir m_dst; int m_cloned; + QList<QPair<QString, QString>> m_failedClones; }; /** |