diff --git a/CHANGES b/CHANGES index 4eb25ff1d..f98ffbda0 100644 --- a/CHANGES +++ b/CHANGES @@ -32,6 +32,13 @@ This release contains contributions from (alphabetically by first name): has been revived and merged. +# 3.2.39.2 (2021-04-02) # + +This is **another** hotfix release for issues around autologin .. +autoLogin, really, since the whole problem is that internal capitalization +changed. (Reported by pcrepix, #1668) + + # 3.2.39.1 (2021-03-30) # This hotfix release corrects a regression in the *displaymanager* diff --git a/src/calamares/CalamaresApplication.cpp b/src/calamares/CalamaresApplication.cpp index 164b3ed5c..08a5606e1 100644 --- a/src/calamares/CalamaresApplication.cpp +++ b/src/calamares/CalamaresApplication.cpp @@ -10,7 +10,7 @@ #include "CalamaresApplication.h" #include "CalamaresConfig.h" -#include "CalamaresVersion.h" +#include "CalamaresVersionX.h" #include "CalamaresWindow.h" #include "progresstree/ProgressTreeView.h" @@ -68,7 +68,7 @@ CalamaresApplication::init() Logger::setupLogfile(); cDebug() << "Calamares version:" << CALAMARES_VERSION; cDebug() << Logger::SubEntry - << " languages:" << QString( CALAMARES_TRANSLATION_LANGUAGES ).replace( ";", ", " ); + << "languages:" << QString( CALAMARES_TRANSLATION_LANGUAGES ).replace( ";", ", " ); if ( !Calamares::Settings::instance() ) { diff --git a/src/modules/keyboard/Config.cpp b/src/modules/keyboard/Config.cpp index a2f200a52..d286e26fd 100644 --- a/src/modules/keyboard/Config.cpp +++ b/src/modules/keyboard/Config.cpp @@ -210,6 +210,10 @@ Config::Config( QObject* parent ) m_setxkbmapTimer.start( QApplication::keyboardInputInterval() ); emit prettyStatusChanged(); } ); + + m_selectedModel = m_keyboardModelsModel->key( m_keyboardModelsModel->currentIndex() ); + m_selectedLayout = m_keyboardLayoutsModel->item( m_keyboardLayoutsModel->currentIndex() ).first; + m_selectedVariant = m_keyboardVariantsModel->key( m_keyboardVariantsModel->currentIndex() ); } KeyboardModelsModel* @@ -528,37 +532,14 @@ Config::setConfigurationMap( const QVariantMap& configurationMap ) { using namespace CalamaresUtils; - if ( configurationMap.contains( "xOrgConfFileName" ) - && configurationMap.value( "xOrgConfFileName" ).type() == QVariant::String - && !getString( configurationMap, "xOrgConfFileName" ).isEmpty() ) + const auto xorgConfDefault = QStringLiteral( "00-keyboard.conf" ); + m_xOrgConfFileName = getString( configurationMap, "xOrgConfFileName", xorgConfDefault ); + if ( m_xOrgConfFileName.isEmpty() ) { - m_xOrgConfFileName = getString( configurationMap, "xOrgConfFileName" ); - } - else - { - m_xOrgConfFileName = "00-keyboard.conf"; - } - - if ( configurationMap.contains( "convertedKeymapPath" ) - && configurationMap.value( "convertedKeymapPath" ).type() == QVariant::String - && !getString( configurationMap, "convertedKeymapPath" ).isEmpty() ) - { - m_convertedKeymapPath = getString( configurationMap, "convertedKeymapPath" ); - } - else - { - m_convertedKeymapPath = QString(); - } - - if ( configurationMap.contains( "writeEtcDefaultKeyboard" ) - && configurationMap.value( "writeEtcDefaultKeyboard" ).type() == QVariant::Bool ) - { - m_writeEtcDefaultKeyboard = getBool( configurationMap, "writeEtcDefaultKeyboard", true ); - } - else - { - m_writeEtcDefaultKeyboard = true; + m_xOrgConfFileName = xorgConfDefault; } + m_convertedKeymapPath = getString( configurationMap, "convertedKeymapPath" ); + m_writeEtcDefaultKeyboard = getBool( configurationMap, "writeEtcDefaultKeyboard", true ); } void diff --git a/src/modules/users/Config.cpp b/src/modules/users/Config.cpp index be87ad93b..2954b0381 100644 --- a/src/modules/users/Config.cpp +++ b/src/modules/users/Config.cpp @@ -820,7 +820,19 @@ Config::setConfigurationMap( const QVariantMap& configurationMap ) m_hostNameActions = getHostNameActions( configurationMap ); setConfigurationDefaultGroups( configurationMap, m_defaultGroups ); - m_doAutoLogin = CalamaresUtils::getBool( configurationMap, "doAutoLogin", false ); + + // Renaming of Autologin -> AutoLogin in 4ffa79d4cf also affected + // configuration keys, which was not intended. Accept both. + const auto oldKey = QStringLiteral( "doAutologin" ); + const auto newKey = QStringLiteral( "doAutoLogin" ); + if ( configurationMap.contains( oldKey ) ) + { + m_doAutoLogin = CalamaresUtils::getBool( configurationMap, oldKey, false ); + } + else + { + m_doAutoLogin = CalamaresUtils::getBool( configurationMap, newKey, false ); + } m_writeRootPassword = CalamaresUtils::getBool( configurationMap, "setRootPassword", true ); Calamares::JobQueue::instance()->globalStorage()->insert( "setRootPassword", m_writeRootPassword );