mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Save / Restore the Tree after organizing by other columns.
This patch saves and restores the state of the TreeView after the user clicks on another columns that will make the tree disappear. All of the branche states are saved, this way the expanded nodes will be restored when the user gets back to tree mode. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
38287a1c1e
commit
d3fe3494fe
2 changed files with 28 additions and 17 deletions
|
@ -49,6 +49,7 @@ signals:
|
|||
|
||||
private:
|
||||
bool mouseClickSelection;
|
||||
QList<int> expandedRows;
|
||||
int sortColumn;
|
||||
Qt::SortOrder currentOrder;
|
||||
DiveTripModel::Layout currentLayout;
|
||||
|
@ -56,6 +57,8 @@ private:
|
|||
QModelIndex contextMenuIndex;
|
||||
void merge_trip(const QModelIndex &a, const int offset);
|
||||
void setupUi();
|
||||
void backupExpandedRows();
|
||||
void restoreExpandedRows();
|
||||
};
|
||||
|
||||
#endif // DIVELISTVIEW_H
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue