diff options
Diffstat (limited to 'mobile-widgets')
-rw-r--r-- | mobile-widgets/qmlmanager.cpp | 6 | ||||
-rw-r--r-- | mobile-widgets/qmlmanager.h | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/mobile-widgets/qmlmanager.cpp b/mobile-widgets/qmlmanager.cpp index d312fac00..9b52ee211 100644 --- a/mobile-widgets/qmlmanager.cpp +++ b/mobile-widgets/qmlmanager.cpp @@ -223,6 +223,9 @@ QMLManager::QMLManager() : m_locationServiceEnabled(false), set_git_update_cb(&gitProgressCB); LOG_STP("qmlmgr git update"); + // present dive site lists sorted by name + locationModel.sort(LocationInformationModel::NAME); + // make sure we know if the current cloud repo has been successfully synced syncLoadFromCloud(); LOG_STP("qmlmgr sync load cloud"); @@ -334,7 +337,8 @@ void QMLManager::updateAllGlobalLists() buddyModel.updateModel(); emit buddyListChanged(); suitModel.updateModel(); emit suitListChanged(); divemasterModel.updateModel(); emit divemasterListChanged(); - locationModel.update(); emit locationListChanged(); + // TODO: Probably not needed anymore, as the dive site list is generated on the fly! + LocationInformationModel::instance()->update(); emit locationListChanged(); } void QMLManager::mergeLocalRepo() diff --git a/mobile-widgets/qmlmanager.h b/mobile-widgets/qmlmanager.h index 7d10f78b2..ff09661c6 100644 --- a/mobile-widgets/qmlmanager.h +++ b/mobile-widgets/qmlmanager.h @@ -209,7 +209,7 @@ private: BuddyCompletionModel buddyModel; SuitCompletionModel suitModel; DiveMasterCompletionModel divemasterModel; - LocationInformationModel locationModel; + DiveSiteSortedModel locationModel; QString m_startPageText; QString m_logText; QString m_lastError; |