summaryrefslogtreecommitdiffstats
path: root/src/libs/installer/settings.cpp
diff options
context:
space:
mode:
authorSlobodan Vrkacevic <slobodan@froglogic.com>2016-05-04 14:31:00 +0200
committerKatja Marttila <katja.marttila@qt.io>2016-05-18 03:09:55 +0000
commit80a655749ffbce4ec6328541e194e08d60b34639 (patch)
treef18b915a6ca62e2708cb825d3d931a02d1268b4b /src/libs/installer/settings.cpp
parent32ecf4e576e60fd1e411b1e0cec2900516ccbace (diff)
Make usage of authorization fallback optional
Asking users to use the authorization fallback in case of authorization errors might be a bit problematic in some cases. If the users are not familiar with the concept, running: "<installer_exe> --startserver PRODUCTION,{GUID},{GUID}" from command line might be confusing or difficult. Also it might not help at all. So let's make this optional. If the config variable DisableAuthorizationFallback is set to true the installer will not ask users to run the authorization fallback but instead it will abort the installation immediately. In RemoteClient this is implemented by adding a new function called setAuthorizationFallbackDisabled. The init function could be also extend for this but the config settings are not loaded at the time when the function is called. Change-Id: I4baf1dea34c5cc0016e98df47a9492ee1418c5ee Reviewed-by: Katja Marttila <katja.marttila@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Diffstat (limited to 'src/libs/installer/settings.cpp')
-rw-r--r--src/libs/installer/settings.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/libs/installer/settings.cpp b/src/libs/installer/settings.cpp
index 3f0845649..3e933574d 100644
--- a/src/libs/installer/settings.cpp
+++ b/src/libs/installer/settings.cpp
@@ -256,7 +256,8 @@ Settings Settings::fromFileAndPrefix(const QString &path, const QString &prefix,
<< scStartMenuDir << scMaintenanceToolName << scMaintenanceToolIniFile << scRemoveTargetDir
<< scRunProgram << scRunProgramArguments << scRunProgramDescription
<< scDependsOnLocalInstallerBinary
- << scAllowSpaceInPath << scAllowNonAsciiCharacters << scWizardStyle << scStyleSheet << scTitleColor
+ << scAllowSpaceInPath << scAllowNonAsciiCharacters << scDisableAuthorizationFallback
+ << scWizardStyle << scStyleSheet << scTitleColor
<< scWizardDefaultWidth << scWizardDefaultHeight
<< scRepositorySettingsPageVisible << scTargetConfigurationFile
<< scRemoteRepositories << scTranslations << scUrlQueryString << QLatin1String(scControlScript)
@@ -520,6 +521,11 @@ bool Settings::allowNonAsciiCharacters() const
return d->m_data.value(scAllowNonAsciiCharacters, false).toBool();
}
+bool Settings::disableAuthorizationFallback() const
+{
+ return d->m_data.value(scDisableAuthorizationFallback, false).toBool();
+}
+
bool Settings::dependsOnLocalInstallerBinary() const
{
return d->m_data.value(scDependsOnLocalInstallerBinary).toBool();