From a626e52bf32cba3900a209e190d02992491e6ccd Mon Sep 17 00:00:00 2001 From: Adriaan de Groot Date: Fri, 8 Jun 2018 17:36:29 -0400 Subject: [PATCH] [libcalamares] Introduce more descriptive type name --- src/libcalamares/Settings.cpp | 2 +- src/libcalamares/Settings.h | 6 ++++-- src/libcalamaresui/modulesystem/ModuleManager.cpp | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/libcalamares/Settings.cpp b/src/libcalamares/Settings.cpp index 732afa8d8..087822623 100644 --- a/src/libcalamares/Settings.cpp +++ b/src/libcalamares/Settings.cpp @@ -175,7 +175,7 @@ Settings::modulesSearchPaths() const } -QList > +Settings::InstanceDescriptionList Settings::customModuleInstances() const { return m_customModuleInstances; diff --git a/src/libcalamares/Settings.h b/src/libcalamares/Settings.h index 42720b986..35527243a 100644 --- a/src/libcalamares/Settings.h +++ b/src/libcalamares/Settings.h @@ -43,7 +43,9 @@ public: QStringList modulesSearchPaths() const; - QList< QMap< QString, QString > > customModuleInstances() const; + using InstanceDescription = QMap< QString, QString >; + using InstanceDescriptionList = QList< InstanceDescription >; + InstanceDescriptionList customModuleInstances() const; QList< QPair< ModuleAction, QStringList > > modulesSequence() const; @@ -60,7 +62,7 @@ private: QStringList m_modulesSearchPaths; - QList< QMap< QString, QString > > m_customModuleInstances; + InstanceDescriptionList m_customModuleInstances; QList< QPair< ModuleAction, QStringList > > m_modulesSequence; QString m_brandingComponentName; diff --git a/src/libcalamaresui/modulesystem/ModuleManager.cpp b/src/libcalamaresui/modulesystem/ModuleManager.cpp index 83273e924..df77c5602 100644 --- a/src/libcalamaresui/modulesystem/ModuleManager.cpp +++ b/src/libcalamaresui/modulesystem/ModuleManager.cpp @@ -159,7 +159,7 @@ ModuleManager::loadModules() { QTimer::singleShot( 0, this, [ this ]() { - QList< QMap< QString, QString > > customInstances = + Settings::InstanceDescriptionList customInstances = Settings::instance()->customModuleInstances(); const auto modulesSequence = Settings::instance()->modulesSequence();