File indexing completed on 2024-12-22 04:15:11
0001 /* 0002 * SPDX-FileCopyrightText: 2021 Agata Cacko cacko.azh@gmail.com 0003 * 0004 * SPDX-License-Identifier: GPL-3.0-or-later 0005 */ 0006 #ifndef DLG_RESOURCE_TYPE_FOR_FILE_H 0007 #define DLG_RESOURCE_TYPE_FOR_FILE_H 0008 0009 #include <KoDialog.h> 0010 #include <QModelIndex> 0011 #include <QPersistentModelIndex> 0012 #include <QStyledItemDelegate> 0013 #include <QWidget> 0014 #include <QMap> 0015 #include <QString> 0016 0017 0018 #include "ui_wdgdlgbundlemanager.h" 0019 0020 class QButtonGroup; 0021 0022 0023 class DlgResourceTypeForFile : public KoDialog 0024 { 0025 0026 Q_OBJECT 0027 public: 0028 0029 DlgResourceTypeForFile(QWidget* parent, QMap<QString, QStringList> resourceTypesForMimetype); 0030 0031 explicit DlgResourceTypeForFile(QWidget *parent = 0); 0032 0033 QString getResourceTypeForMimetype(QString mimetype); 0034 0035 0036 private: 0037 QMap<QString, QButtonGroup*> m_buttonGroupForMimetype; 0038 const QString m_propertyName {"resourceType"}; 0039 }; 0040 0041 #endif // DLG_RESOURCE_TYPE_FOR_FILE_H