blob: fd93514cf2cf1163cdae9480930c3a31c82e6de8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
#include "modinfodialogfwd.h"
#include "modinfo.h"
#include <QPushButton>
#include <QTreeWidget>
#include <QCheckBox>
namespace Ui { class MainWindow; }
class OrganizerCore;
class Settings;
class PluginContainer;
class FileTree;
namespace MOShared { class DirectoryEntry; }
class DataTab : public QObject
{
Q_OBJECT;
public:
DataTab(
OrganizerCore& core, PluginContainer& pc,
QWidget* parent, Ui::MainWindow* ui);
void saveState(Settings& s) const;
void restoreState(const Settings& s);
void activated();
void refreshDataTreeKeepExpandedNodes();
void refreshDataTree();
signals:
void executablesChanged();
void originModified(int originID);
void displayModInformation(ModInfo::Ptr m, unsigned int i, ModInfoTabIDs tab);
private:
struct DataTabUi
{
QPushButton* refresh;
QTreeView* tree;
QCheckBox* conflicts;
QCheckBox* archives;
};
OrganizerCore& m_core;
PluginContainer& m_pluginContainer;
QWidget* m_parent;
DataTabUi ui;
std::unique_ptr<FileTree> m_filetree;
std::vector<QTreeWidgetItem*> m_removeLater;
void onRefresh();
void onItemExpanded(QTreeWidgetItem* item);
void onConflicts();
void onArchives();
void updateOptions();
};
|