summaryrefslogtreecommitdiff
path: root/src/modinfodialogfiletree.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/modinfodialogfiletree.h')
-rw-r--r--src/modinfodialogfiletree.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/src/modinfodialogfiletree.h b/src/modinfodialogfiletree.h
new file mode 100644
index 00000000..e7708ab8
--- /dev/null
+++ b/src/modinfodialogfiletree.h
@@ -0,0 +1,39 @@
+#ifndef MODINFODIALOGFILETREE_H
+#define MODINFODIALOGFILETREE_H
+
+#include "modinfodialogtab.h"
+
+class FileTreeTab : public ModInfoDialogTab
+{
+public:
+ FileTreeTab(
+ OrganizerCore& oc, PluginContainer& plugin,
+ QWidget* parent, Ui::ModInfoDialog* ui);
+
+ void clear() override;
+ void update() override;
+
+private:
+ struct Actions
+ {
+ QAction *newFolder = nullptr;
+ QAction *open = nullptr;
+ QAction *preview = nullptr;
+ QAction *rename = nullptr;
+ QAction *del = nullptr;
+ QAction *hide = nullptr;
+ QAction *unhide = nullptr;
+ };
+
+ QFileSystemModel* m_fs;
+ Actions m_actions;
+
+ QModelIndex singleSelection() const;
+ void onCreateDirectory();
+ void onOpen();
+ void onPreview();
+ void onRename();
+ void onDelete();
+};
+
+#endif // MODINFODIALOGFILETREE_H