digiKam
albumpropsedit.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 : 2003-03-09
7  * Description : Album properties dialog.
8  *
9  * Copyright (C) 2003-2004 by Renchi Raju <renchi dot raju at gmail dot com>
10  * Copyright (C) 2005 by Tom Albers <tomalbers at kde dot nl>
11  * Copyright (C) 2006-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
12  *
13  * This program is free software; you can redistribute it
14  * and/or modify it under the terms of the GNU General
15  * Public License as published by the Free Software Foundation;
16  * either version 2, or (at your option)
17  * any later version.
18  *
19  * This program is distributed in the hope that it will be useful,
20  * but WITHOUT ANY WARRANTY; without even the implied warranty of
21  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22  * GNU General Public License for more details.
23  *
24  * ============================================================ */
25 
26 #ifndef DIGIKAM_ALBUM_PROPS_EDIT_H
27 #define DIGIKAM_ALBUM_PROPS_EDIT_H
28 
29 // Qt includes
30 
31 #include <QString>
32 #include <QStringList>
33 #include <QDialog>
34 
35 namespace Digikam
36 {
37 
38 class PAlbum;
39 
40 class AlbumPropsEdit : public QDialog
41 {
42  Q_OBJECT
43 
44 public:
45 
46  explicit AlbumPropsEdit(PAlbum* const album, bool create = false);
47  ~AlbumPropsEdit() override;
48 
49  QString title() const;
50  QString comments() const;
51  QDate date() const;
52  int parent() const;
53  QString category() const;
54  QStringList albumCategories() const;
55 
56 public:
57 
58  static bool editProps(PAlbum* const album,
59  QString& title,
60  QString& comments,
61  QDate& date,
62  QString& category,
63  QStringList& albumCategories);
64 
65  static bool createNew(PAlbum* const parent,
66  QString& title,
67  QString& comments,
68  QDate& date,
69  QString& category,
70  QStringList& albumCategories,
71  int& parentSelector);
72 
73 private Q_SLOTS:
74 
75  void slotTitleChanged(const QString& newtitle);
76  void slotNewAlbumTextChanged(int index);
77  void slotDateLowButtonClicked();
78  void slotDateAverageButtonClicked();
79  void slotDateHighButtonClicked();
80  void slotHelp();
81 
82 private:
83 
84  // Disable
85  explicit AlbumPropsEdit(QWidget*) = delete;
86 
87 private:
88 
89  class Private;
90  Private* const d;
91 };
92 
93 } // namespace Digikam
94 
95 #endif // DIGIKAM_ALBUM_PROPS_EDIT_H
Definition: albumpropsedit.h:41
QDate date() const
Definition: albumpropsedit.cpp:341
int parent() const
Definition: albumpropsedit.cpp:350
AlbumPropsEdit(PAlbum *const album, bool create=false)
Definition: albumpropsedit.cpp:121
QString title() const
Definition: albumpropsedit.cpp:331
QString comments() const
Definition: albumpropsedit.cpp:336
QStringList albumCategories() const
Definition: albumpropsedit.cpp:367
static bool editProps(PAlbum *const album, QString &title, QString &comments, QDate &date, QString &category, QStringList &albumCategories)
Definition: albumpropsedit.cpp:389
~AlbumPropsEdit() override
Definition: albumpropsedit.cpp:326
QString category() const
Definition: albumpropsedit.cpp:355
static bool createNew(PAlbum *const parent, QString &title, QString &comments, QDate &date, QString &category, QStringList &albumCategories, int &parentSelector)
Definition: albumpropsedit.cpp:407
Definition: album.h:357
Definition: datefolderview.cpp:43