digiKam
thumbnailtask.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2007-06-05
7  * Description : Multithreaded loader for thumbnails
8  *
9  * Copyright (C) 2006-2008 by Marcel Wiesweg <marcel dot wiesweg at gmx dot de>
10  * Copyright (C) 2006-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
11  *
12  * This program is free software; you can redistribute it
13  * and/or modify it under the terms of the GNU General
14  * Public License as published by the Free Software Foundation;
15  * either version 2, or (at your option)
16  * any later version.
17  *
18  * This program is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21  * GNU General Public License for more details.
22  *
23  * ============================================================ */
24 
25 #ifndef DIGIKAM_THUMB_NAIL_TASK_H
26 #define DIGIKAM_THUMB_NAIL_TASK_H
27 
28 // Qt includes
29 
30 #include <QImage>
31 
32 // Local includes
33 
34 #include "loadsavetask.h"
35 
36 namespace Digikam
37 {
38 
39 class ThumbnailCreator;
40 
42 {
43 public:
44 
45  explicit ThumbnailLoadingTask(LoadSaveThread* const thread,
46  const LoadingDescription& description);
47 
48  void execute() override;
49  void postProcess() override;
51  const QImage& qimage);
52 
53 private:
54 
55  void setupCreator();
56 
57 private:
58 
59  QImage m_qimage;
60  ThumbnailCreator* m_creator;
61 
62 private:
63 
64  // Disable
66  ThumbnailLoadingTask& operator=(const ThumbnailLoadingTask&) = delete;
67 };
68 
69 } // namespace Digikam
70 
71 #endif // DIGIKAM_THUMB_NAIL_TASK_H
Definition: loadsavethread.h:103
Definition: loadingdescription.h:45
const LoadingDescription & loadingDescription() const
Definition: loadsavetask.cpp:74
Definition: loadsavetask.h:134
Definition: thumbnailcreator.h:51
Definition: thumbnailtask.h:42
void postProcess() override
Definition: thumbnailtask.cpp:262
void execute() override
Definition: thumbnailtask.cpp:64
void setThumbResult(const LoadingDescription &loadingDescription, const QImage &qimage)
Definition: thumbnailtask.cpp:248
ThumbnailLoadingTask(LoadSaveThread *const thread, const LoadingDescription &description)
Definition: thumbnailtask.cpp:51
Definition: datefolderview.cpp:43