1 #ifndef _RESTORETREE_H_
2 #define _RESTORETREE_H_
5 Bacula(R) - The Network Backup Solution
7 Copyright (C) 2000-2015 Kern Sibbald
8 Copyright (C) 2007-2014 Free Software Foundation Europe e.V.
10 The original author of Bacula is Kern Sibbald, with contributions
11 from many others, a complete list can be found in the file AUTHORS.
13 You may use this file and others of this release according to the
14 license defined in the LICENSE file, which includes the Affero General
15 Public License, v3.0 ("AGPLv3") and some additional permissions and
16 terms pursuant to its AGPLv3 Section 7.
18 This notice must be preserved when any source code is
19 conveyed and/or propagated.
21 Bacula(R) is a registered trademark of Kern Sibbald.
24 * Kern Sibbald, February 2007
29 #include "ui_restoretree.h"
33 * A restore tree to view files in the catalog
35 class restoreTree : public Pages, public Ui::restoreTreeForm
42 virtual void PgSeltreeWidgetClicked();
43 virtual void currentStackItem();
47 FolderGreenChecked = 1,
48 FolderWhiteChecked = 2,
53 void refreshButtonPushed();
54 void restoreButtonPushed();
55 void jobComboChanged(int);
56 void directoryCurrentItemChanged(QTreeWidgetItem *, QTreeWidgetItem *);
57 void fileCurrentItemChanged(QTableWidgetItem *,QTableWidgetItem *);
58 void directoryItemExpanded(QTreeWidgetItem *);
59 void setCheckofChildren(QTreeWidgetItem *item, Qt::CheckState);
60 void directoryItemChanged(QTreeWidgetItem *, int);
61 void fileTableItemChanged(QTableWidgetItem *);
62 void versionTableItemChanged(QTableWidgetItem *);
64 void jobTableCellClicked(int, int);
67 void populateDirectoryTree();
68 void populateJobTable();
69 void parseDirectory(const QString &dir_in);
73 void fileExceptionInsert(QString &, QString &, Qt::CheckState);
74 void fileExceptionRemove(QString &, QString &);
75 void directoryTreeDisconnectedSet(QTreeWidgetItem *, Qt::CheckState);
76 void fileTableDisconnectedSet(QTableWidgetItem *, Qt::CheckState, bool color);
77 void versionTableDisconnectedSet(QTableWidgetItem *, Qt::CheckState);
78 void updateFileTableChecks();
79 void updateVersionTableChecks();
80 void directoryIconStateInsert(QString &, Qt::CheckState);
81 void directoryIconStateRemove();
82 void directorySetIcon(int operation, int change, QString &, QTreeWidgetItem* item);
83 void fullPathtoSubPaths(QStringList &, QString &);
84 int mostRecentVersionfromFullPath(QString &);
85 void setJobsCheckedList();
86 int queryFileIndex(QString &fullPath, int jobID);
88 QSplitter *m_splitter;
93 bool m_dropdownChanged;
95 QHash<QString, QTreeWidgetItem *> m_dirPaths;
96 QString m_checkedJobs, m_prevJobCombo, m_prevClientCombo, m_prevFileSetCombo;
97 int m_prevLimitSpinBox, m_prevDaysSpinBox;
98 Qt::CheckState m_prevLimitCheckState, m_prevDaysCheckState;
99 QString m_JobsCheckedList;
102 QList<Qt::CheckState> m_fileCheckStateList;
103 QList<Qt::CheckState> m_versionCheckStateList;
104 QHash<QString, Qt::CheckState> m_fileExceptionHash;
105 QMultiHash<QString, QString> m_fileExceptionMulti;
106 QHash<QString, int> m_versionExceptionHash;
107 QHash<QString, int> m_directoryIconStateHash;
108 QHash<QString, int> m_directoryPathIdHash;
109 int m_toggleUpIndex, m_toggleDownIndex, m_nullFileNameId;
112 #endif /* _RESTORETREE_H_ */