digiKam
blackframelistview.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 : 2005-07-05
7  * Description : a list view to display black frames
8  *
9  * Copyright (C) 2005-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
10  * Copyright (C) 2005-2006 by Unai Garro <ugarro at users dot sourceforge dot net>
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_BLACK_FRAME_LIST_VIEW_H
26 #define DIGIKAM_BLACK_FRAME_LIST_VIEW_H
27 
28 // Qt includes
29 
30 #include <QList>
31 #include <QUrl>
32 #include <QTreeWidget>
33 
34 // Local includes
35 
36 #include "digikam_export.h"
37 #include "hotpixelprops.h"
38 
39 namespace Digikam
40 {
41 
42 class DIGIKAM_EXPORT BlackFrameListView : public QTreeWidget
43 {
44  Q_OBJECT
45 
46 public:
47 
48  explicit BlackFrameListView(QWidget* const parent = nullptr);
49  ~BlackFrameListView() override;
50 
51  bool contains(const QUrl& url);
52  bool isSelected(const QUrl& url);
53  QUrl currentUrl();
54 
55 Q_SIGNALS:
56 
58  void signalBlackFrameRemoved(const QUrl&);
60 
61 private Q_SLOTS:
62 
63  void slotSelectionChanged();
64  void slotHotPixelsParsed(const QList<HotPixelProps>&, const QUrl&);
65  void slotToolTip();
66  void slotContextMenu();
67 
68 private:
69 
70  void hideToolTip();
71  bool acceptToolTip(const QPoint& pos) const;
72 
73  void mouseMoveEvent(QMouseEvent*) override;
74  void wheelEvent(QWheelEvent*) override;
75  void keyPressEvent(QKeyEvent*) override;
76  void focusOutEvent(QFocusEvent*) override;
77  void leaveEvent(QEvent*) override;
78 
79 private:
80 
81  class Private;
82  Private* const d;
83 };
84 
85 } // namespace Digikam
86 
87 #endif // DIGIKAM_BLACK_FRAME_LIST_VIEW_H
Definition: blackframelistview.h:43
void signalBlackFrameSelected(const QList< HotPixelProps > &, const QUrl &)
void signalBlackFrameRemoved(const QUrl &)
Definition: piwigotalker.h:48
Definition: datefolderview.cpp:43