blob: 82bc46e4a651a466d8448288f872ba5ea7ff6cb8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
#ifndef MIRALL_UNISONFOLDER_H
#define MIRALL_UNISONFOLDER_H
#include <QMutex>
#include <QProcess>
#include <QStringList>
#include "mirall/folder.h"
class QProcess;
namespace Mirall {
class UnisonFolder : public Folder
{
Q_OBJECT
public:
UnisonFolder(const QString &path, const QString &secondPath, QObject *parent = 0L);
virtual ~UnisonFolder();
QString secondPath() const;
virtual void startSync(const QStringList &pathList);
virtual bool isBusy() const;
protected slots:
void slotReadyReadStandardOutput();
void slotReadyReadStandardError();
void slotStateChanged(QProcess::ProcessState);
void slotFinished(int exitCode, QProcess::ExitStatus exitStatus);
void slotStarted();
void slotError(QProcess::ProcessError);
private:
QMutex _syncMutex;
QProcess *_unison;
QString _secondPath;
int _syncCount;
};
}
#endif
|