digiKam
itemattributeswatch.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 : 2006-05-04
7  * Description : Watch image attributes
8  *
9  * Copyright (C) 2006-2011 by Marcel Wiesweg <marcel dot wiesweg at gmx dot de>
10  *
11  * This program is free software; you can redistribute it
12  * and/or modify it under the terms of the GNU General
13  * Public License as published by the Free Software Foundation;
14  * either version 2, or (at your option)
15  * any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * ============================================================ */
23 
24 #ifndef DIGIKAM_ITEM_ATTRIBUTES_WATCH_H
25 #define DIGIKAM_ITEM_ATTRIBUTES_WATCH_H
26 
27 // Qt includes
28 
29 #include <QObject>
30 #include <QUrl>
31 
32 // Local includes
33 
34 #include "coredbchangesets.h"
35 #include "digikam_export.h"
36 
37 namespace Digikam
38 {
39 
40 class DIGIKAM_DATABASE_EXPORT ItemAttributesWatch : public QObject
41 {
42  Q_OBJECT
43 
44 public:
45 
46  static ItemAttributesWatch* instance();
47  static void cleanUp();
48  static void shutDown();
49 
50 /*
51  void imageTagsChanged(qint64 imageId);
52  void imagesChanged(int albumId);
53 
54  void imageRatingChanged(qint64 imageId);
55  void imageDateChanged(qint64 imageId);
56  void imageCaptionChanged(qint64 imageId);
57 */
58 
59  void fileMetadataChanged(const QUrl& url);
60 
61 Q_SIGNALS:
62 
69  void signalImageTagsChanged(qlonglong imageId);
70 
75  void signalImagesChanged(int albumId);
76 
82  void signalImageRatingChanged(qlonglong imageId);
83  void signalImageDateChanged(qlonglong imageId);
84  void signalImageCaptionChanged(qlonglong imageId);
85 
92  void signalFileMetadataChanged(const QUrl& url);
93 
94 private Q_SLOTS:
95 
96  void slotImageChange(const ImageChangeset& changeset);
97  void slotImageTagChange(const ImageTagChangeset& changeset);
98 
99 private:
100 
101  // Disable
103  explicit ItemAttributesWatch(QObject*) = delete;
104  ~ItemAttributesWatch() override;
105 
106  static ItemAttributesWatch* m_instance;
107 };
108 
109 } // namespace Digikam
110 
111 #endif // DIGIKAM_ITEM_ATTRIBUTES_WATCH_H
Definition: coredbchangesets.h:48
Definition: coredbchangesets.h:80
Definition: itemattributeswatch.h:41
void signalFileMetadataChanged(const QUrl &url)
void signalImageTagsChanged(qlonglong imageId)
void signalImagesChanged(int albumId)
void signalImageDateChanged(qlonglong imageId)
void signalImageCaptionChanged(qlonglong imageId)
void signalImageRatingChanged(qlonglong imageId)
Definition: datefolderview.cpp:43