2018-05-13 07:52:49 +00:00
|
|
|
#ifndef PREFERENCECATEGORY_H
|
|
|
|
#define PREFERENCECATEGORY_H
|
|
|
|
|
|
|
|
#include <QString>
|
|
|
|
#include <QTreeWidget>
|
|
|
|
#include <QStackedWidget>
|
|
|
|
|
|
|
|
class PreferenceCategory
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
PreferenceCategory(const QString &name, const QIcon &icon);
|
|
|
|
PreferenceCategory(const QString &name, QWidget *widget, const QIcon &icon);
|
|
|
|
PreferenceCategory(const QString &name, QWidget *widget, const QIcon &icon,
|
|
|
|
const QList<PreferenceCategory> &children);
|
|
|
|
PreferenceCategory(const QString &name, const QIcon &icon,
|
|
|
|
const QList<PreferenceCategory> &children);
|
|
|
|
|
|
|
|
void addItem(QTreeWidget &tree, QStackedWidget &panel);
|
|
|
|
void addItem(QTreeWidgetItem &tree, QStackedWidget &panel);
|
|
|
|
|
|
|
|
private:
|
2018-05-13 19:38:53 +00:00
|
|
|
QString name;
|
|
|
|
QIcon icon;
|
2018-05-13 07:52:49 +00:00
|
|
|
QWidget *widget;
|
|
|
|
QList<PreferenceCategory> children;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif //PREFERENCECATEGORY_H
|