-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathenexport.h
54 lines (39 loc) · 1.1 KB
/
enexport.h
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
44
45
46
47
48
49
50
51
52
53
54
#ifndef ENEXPORT_H
#define ENEXPORT_H
#include <QtCore>
#include <QtXml>
#include <QtWebKit/QWebView>
class EnNote;
//! Êëàññ, îáåñïå÷èâàþùèé ðàáîòó ñ ðàçìåòêîé ýêñïîðòà evernote.
class EnExport: public QThread
{
Q_OBJECT
public:
friend class Test_EnExport;
//! Îïðåäåëÿåòñÿ ïóòü ê èñïëíÿåìûì ôàéëàì evernote.
explicit EnExport(QObject* parent = 0);
~EnExport();
void run();
//! Îòïðàâëÿåò çàïðîñ @p query â evernote. Âîçâðàùàåò true, åñëè çàïðîñ îòïðàâëåí, èíà÷å false.
bool loadNotes(const QString& query);
void setNotesToView(QWebView*);
QList<EnNote*> getNotes() const;
void setQuery(const QString&);
bool isExportAvaliable() const;
signals:
//! Ñèãíàë, ïîñûëàåòñÿ êîãäà ýêñïîðò çàìåòîê çàâåðø¸í.
void exported();
public slots:
void openNote(const QString&);
private slots:
//! Ñëîò, îáðàáàòûâàþùèé ïîëó÷åííûå îò ïðîöåññà mEnProcess äàííûå.
void readExport();
private:
QTime mTimer;
QString mEnScriptPath;
QString mEvernotePath;
QString mQuery;
QProcess* mEnProcess;
QList<EnNote*> mEnNotes;
};
#endif // ENEXPORT_H