From 89e0c3f46498ba3e0844514b6709a07c200a68df Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Wed, 25 Jul 2018 21:23:19 +0200 Subject: Cleanup: make DiveTripModel a global object DiveTripModel (the model describing the dive-list) was destroyed and recreated on every reset of the list. This seems excessive. Instead - in analogy to most other models - make it a single global object. Signed-off-by: Berthold Stoeger --- desktop-widgets/divelistview.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'desktop-widgets/divelistview.h') diff --git a/desktop-widgets/divelistview.h b/desktop-widgets/divelistview.h index 396bef8ce..7e2b6425d 100644 --- a/desktop-widgets/divelistview.h +++ b/desktop-widgets/divelistview.h @@ -78,7 +78,7 @@ private: QMultiHash selectedDives; void merge_trip(const QModelIndex &a, const int offset); void setColumnWidths(); - void calculateInitialColumnWidth(const DiveTripModel &tripModel, int col); + void calculateInitialColumnWidth(int col); void backupExpandedRows(); void restoreExpandedRows(); int lastVisibleColumn(); -- cgit v1.2.3-70-g09d2