2021-06-19 05:29:48 +05:30
|
|
|
#pragma once
|
|
|
|
|
2022-08-10 23:16:28 +05:30
|
|
|
#include "ResourceFolderModel.h"
|
2021-06-19 05:29:48 +05:30
|
|
|
|
2022-08-10 23:18:34 +05:30
|
|
|
#include "ResourcePack.h"
|
|
|
|
|
2022-08-10 23:16:28 +05:30
|
|
|
class ResourcePackFolderModel : public ResourceFolderModel
|
2021-06-19 05:29:48 +05:30
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
2022-08-29 07:03:44 +05:30
|
|
|
enum Columns
|
|
|
|
{
|
|
|
|
ActiveColumn = 0,
|
|
|
|
NameColumn,
|
|
|
|
PackFormatColumn,
|
|
|
|
DateColumn,
|
|
|
|
NUM_COLUMNS
|
|
|
|
};
|
|
|
|
|
2023-04-30 08:08:51 +05:30
|
|
|
explicit ResourcePackFolderModel(const QString &dir, std::shared_ptr<const BaseInstance> instance);
|
2022-08-10 23:18:34 +05:30
|
|
|
|
2022-08-29 07:03:44 +05:30
|
|
|
[[nodiscard]] QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override;
|
|
|
|
|
|
|
|
[[nodiscard]] QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const override;
|
|
|
|
[[nodiscard]] int columnCount(const QModelIndex &parent) const override;
|
|
|
|
|
|
|
|
[[nodiscard]] Task* createUpdateTask() override;
|
|
|
|
[[nodiscard]] Task* createParseTask(Resource&) override;
|
|
|
|
|
2022-08-10 23:18:34 +05:30
|
|
|
RESOURCE_HELPERS(ResourcePack)
|
2021-06-19 05:29:48 +05:30
|
|
|
};
|