From 48792c07a554b5377e3715b85347cc9bb6aa7331 Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Tue, 23 May 2023 10:22:30 +0000 Subject: [PATCH] Revert "Android: Use direct member for aspect" This reverts commit ffd0f7306b09ce7a2538758acb16b24b6f73ee95. Reason for revert: Breaks build. Revert is temporary, will be reapplied after I6eefe739b3aebcef1ece196ff8d70aa36738997b is in Change-Id: I5029f710656fb89eeaf65b55742678938f249aeb Reviewed-by: hjk --- src/plugins/android/androiddeployqtstep.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/plugins/android/androiddeployqtstep.cpp b/src/plugins/android/androiddeployqtstep.cpp index b8b8b8cc2ae..f33ae5aa6b3 100644 --- a/src/plugins/android/androiddeployqtstep.cpp +++ b/src/plugins/android/androiddeployqtstep.cpp @@ -122,7 +122,7 @@ private: QMap m_filesToPull; QStringList m_androidABIs; - BoolAspect m_uninstallPreviousPackage{this}; + BoolAspect *m_uninstallPreviousPackage = nullptr; bool m_uninstallPreviousPackageRun = false; bool m_useAndroiddeployqt = false; bool m_askForUninstall = false; @@ -142,18 +142,18 @@ AndroidDeployQtStep::AndroidDeployQtStep(BuildStepList *parent, Id id) { setImmutable(true); setUserExpanded(true); - setOwnsSubAspects(false); - m_uninstallPreviousPackage.setSettingsKey(UninstallPreviousPackageKey); - m_uninstallPreviousPackage.setLabel(Tr::tr("Uninstall the existing app before deployment"), - BoolAspect::LabelPlacement::AtCheckBox); - m_uninstallPreviousPackage.setValue(false); + m_uninstallPreviousPackage = addAspect(); + m_uninstallPreviousPackage->setSettingsKey(UninstallPreviousPackageKey); + m_uninstallPreviousPackage->setLabel(Tr::tr("Uninstall the existing app before deployment"), + BoolAspect::LabelPlacement::AtCheckBox); + m_uninstallPreviousPackage->setValue(false); const QtSupport::QtVersion * const qt = QtSupport::QtKitAspect::qtVersion(kit()); const bool forced = qt && qt->qtVersion() < QVersionNumber(5, 4, 0); if (forced) { - m_uninstallPreviousPackage.setValue(true); - m_uninstallPreviousPackage.setEnabled(false); + m_uninstallPreviousPackage->setValue(true); + m_uninstallPreviousPackage->setEnabled(false); } connect(this, &AndroidDeployQtStep::askForUninstall, @@ -274,7 +274,7 @@ bool AndroidDeployQtStep::init() emit addOutput(Tr::tr("Deploying to %1").arg(m_serialNumber), OutputFormat::NormalMessage); - m_uninstallPreviousPackageRun = m_uninstallPreviousPackage(); + m_uninstallPreviousPackageRun = m_uninstallPreviousPackage->value(); if (m_uninstallPreviousPackageRun) m_manifestName = AndroidManager::manifestPath(target());