From edea3012527419d87839cd04bbe042a58ba53759 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Tue, 29 Jul 2014 09:11:42 -0700 Subject: [PATCH] Don't mess with the selection when closing a file Our core structures are kept consistent by calling delete_single_dive() and there is no reason at all to even touch the UI selection as this all goes away with cleanUpEmpty() Fixes #660 Signed-off-by: Dirk Hohndel --- qt-ui/mainwindow.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp index c84766038..194ea1acb 100644 --- a/qt-ui/mainwindow.cpp +++ b/qt-ui/mainwindow.cpp @@ -265,10 +265,6 @@ void MainWindow::closeCurrentFile() while (dive_table.nr) delete_single_dive(0); - ui.ListWidget->clearSelection(); - /* clear the selection and the statistics */ - selected_dive = -1; - free((void *)existing_filename); existing_filename = NULL;