@@ -19,28 +19,34 @@
22−#ifndef MYTYPE_H
22+#ifndef MOCKDOWNLOADTRACKER_H
23−#define MYTYPE_H
23+#define MOCKDOWNLOADTRACKER_H
25#include <QObject>
25#include <QObject>
28−class DownloadTracker : public QObject
27+class MockDownloadTracker : public QObject
31− Q_DISABLE_COPY(DownloadTracker)
30+ Q_DISABLE_COPY(MockDownloadTracker)
32− Q_PROPERTY(QString service WRITE setService)
31+ Q_PROPERTY(QString service READ service WRITE setService NOTIFY serviceChanged)
33− Q_PROPERTY(QString dbusPath WRITE setDbusPath)
32+ Q_PROPERTY(QString dbusPath READ dbusPath WRITE setDbusPath NOTIFY dbusPathChanged)
34− Q_PROPERTY(bool serviceReady READ isServiceReady)
33+ Q_PROPERTY(bool serviceReady READ isServiceReady NOTIFY serviceReadyChanged)
37− explicit DownloadTracker(QObject *parent = 0);
36+ explicit MockDownloadTracker(QObject *parent = 0);
38+ QString service() const;
39+ QString dbusPath() const;
40+ bool isServiceReady() const;
39− void setDbusPath(QString& path);
42+ void setDbusPath(const QString& path);
40− void setService(QString& service);
43+ void setService(const QString& service);
41− bool isServiceReady();
46+ void serviceChanged(const QString &service);
47+ void dbusPathChanged(const QString &dbusPath);
48+ void serviceReadyChanged(const bool &serviceReady);
44 void canceled(bool success);
50 void canceled(bool success);
45 void error(const QString &error);
51 void error(const QString &error);
46 void finished(const QString &path);
52 void finished(const QString &path);
@@ -52,9 +58,9 @@ Q_SIGNALS:
53 QString m_dbusPath;
59 QString m_dbusPath;
54 QString m_service;
60 QString m_service;
55− bool active = false;
61+ bool m_active = false;
57 void startService();
63 void startService();
60−#endif // MYTYPE_H
66+#endif // MOCKDOWNLOADTRACKER_H