OSDN Git Service

Ver0.22
[gefu/Gefu.git] / thumbnailworker.h
1 #ifndef THUMBNAILWORKER_H
2 #define THUMBNAILWORKER_H
3
4 #include <QObject>
5 #include <QMutex>
6 #include <QSize>
7 #include <QPixmap>
8
9 class ThumbnailWorker : public QObject
10 {
11     Q_OBJECT
12 public:
13     explicit ThumbnailWorker(QObject *parent = 0);
14
15     void    addPath(const QString &path);
16     void    clearPath();
17     void    finish();
18
19 private:
20     QMutex      m_mutex;
21     QStringList m_pathList;
22     bool        m_loop;
23
24     QString     getPath();
25     bool        loop();
26
27 signals:
28     void    finished();
29     void    resultReady(const QString &path, const QPixmap &pixmap);
30
31 public slots:
32     void    doWork();
33 };
34
35 #endif // THUMBNAILWORKER_H