]> cloud.milkyroute.net Git - dolphin.git/blob - src/settings/filemetadataconfigurationdialog.h
It was a bad idea to store the enabled additional-information as bit-values: With...
[dolphin.git] / src / settings / filemetadataconfigurationdialog.h
1 /***************************************************************************
2 * Copyright (C) 2010 by Peter Penz <peter.penz@gmx.at> *
3 * *
4 * This program is free software; you can redistribute it and/or modify *
5 * it under the terms of the GNU General Public License as published by *
6 * the Free Software Foundation; either version 2 of the License, or *
7 * (at your option) any later version. *
8 * *
9 * This program is distributed in the hope that it will be useful, *
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
12 * GNU General Public License for more details. *
13 * *
14 * You should have received a copy of the GNU General Public License *
15 * along with this program; if not, write to the *
16 * Free Software Foundation, Inc., *
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
18 ***************************************************************************/
19
20 #ifndef FILEMETADATACONFIGURATIONDIALOG_H
21 #define FILEMETADATACONFIGURATIONDIALOG_H
22
23 #include <kdialog.h>
24 #include <kfileitem.h>
25 #include <libdolphin_export.h>
26
27 class QLabel;
28 class KFileMetaDataConfigurationWidget;
29
30 /**
31 * @brief Dialog which allows to configure which meta data should be shown
32 * in the KFileMetaDataWidget.
33 */
34 class LIBDOLPHINPRIVATE_EXPORT FileMetaDataConfigurationDialog : public KDialog
35 {
36 Q_OBJECT
37
38 public:
39 explicit FileMetaDataConfigurationDialog(QWidget* parent = 0);
40 virtual ~FileMetaDataConfigurationDialog();
41
42 /**
43 * Sets the items, for which the visibility of the meta data should
44 * be configured. Note that the visibility of the meta data is not
45 * bound to the items itself, the items are only used to determine
46 * which meta data should be configurable. For example when a JPEG image
47 * is set as item, it will be configurable which EXIF data should be
48 * shown. If an audio file is set as item, it will be configurable
49 * whether the artist, album name, ... should be shown.
50 */
51 void setItems(const KFileItemList& items);
52 KFileItemList items() const;
53
54 /**
55 * Sets the description that is shown above the list
56 * of meta data. Per default the translated text for
57 * "Select which data should be shown." is set.
58 */
59 void setDescription(const QString& description);
60 QString description() const;
61
62 protected slots:
63 virtual void slotButtonClicked(int button);
64
65 private:
66 QLabel* m_descriptionLabel;
67 KFileMetaDataConfigurationWidget* m_configWidget;
68 };
69
70 #endif