SVN_SILENT made messages (after extraction)
[kdepim.git] / ktnef / attachpropertydialog.h
blobacce9bed49b7c351568660f6e42c0359550d0b23
1 /*
2 This file is part of KTnef.
4 Copyright (C) 2002 Michael Goffioul <kdeprint@swing.be>
5 Copyright (c) 2012 Allen Winter <winter@kde.org>
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
12 You should have received a copy of the GNU General Public License
13 along with this program; if not, write to the Free Software Foundation,
14 Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
17 #ifndef ATTACHPROPERTYDIALOG_H
18 #define ATTACHPROPERTYDIALOG_H
20 #include "ui_attachpropertywidgetbase.h"
22 #include <QDialog>
24 #include <QMap>
25 #include <QPixmap>
27 namespace KTnef
29 class KTNEFAttach;
30 class KTNEFProperty;
31 class KTNEFPropertySet;
33 using namespace KTnef;
35 class QTreeWidget;
36 class QTreeWidgetItem;
38 class AttachPropertyDialog : public QDialog
40 Q_OBJECT
41 public:
42 explicit AttachPropertyDialog(QWidget *parent = Q_NULLPTR);
43 ~AttachPropertyDialog();
45 void setAttachment(KTNEFAttach *attach);
47 static QPixmap loadRenderingPixmap(KTNEFPropertySet *, const QColor &);
48 static void formatProperties(const QMap<int, KTNEFProperty *> &, QTreeWidget *,
49 QTreeWidgetItem *, const QString & = QStringLiteral("prop"));
50 static void formatPropertySet(KTNEFPropertySet *, QTreeWidget *);
51 static bool saveProperty(QTreeWidget *, KTNEFPropertySet *, QWidget *);
53 private Q_SLOTS:
54 void slotSave();
56 protected:
57 Ui::AttachPropertyWidgetBase mUI;
59 private:
60 void readConfig();
61 void writeConfig();
62 KTNEFAttach *mAttach;
65 #endif