From 6dc1dcaea52e383803a620369567684f553ede80 Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Wed, 3 Oct 2018 21:45:50 +0200 Subject: Import: pass "downloaded" parameter to process_imported_dives() process_imported_dives() is more efficient for downloaded than for imported (from a file) dives, because it checks only the divecomputer of the first dive. This condition is checked via the "downloaded" flag of the first dive. Instead, pass an argument to process_imported_dives(). Signed-off-by: Berthold Stoeger --- mobile-widgets/qmlmanager.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'mobile-widgets') diff --git a/mobile-widgets/qmlmanager.cpp b/mobile-widgets/qmlmanager.cpp index 4927899de..3bd806034 100644 --- a/mobile-widgets/qmlmanager.cpp +++ b/mobile-widgets/qmlmanager.cpp @@ -325,8 +325,9 @@ void QMLManager::updateAllGlobalLists() void QMLManager::mergeLocalRepo() { char *filename = NOCLOUD_LOCALSTORAGE; - parse_file(filename, &dive_table); - process_imported_dives(false); + struct dive_table table = { 0 }; + parse_file(filename, &table); + process_imported_dives(&table, false, false); } void QMLManager::copyAppLogToClipboard() -- cgit v1.2.3-70-g09d2