Fix Next button behviour for all combinations of
enableLuksAutomatedPartitioning and preCheckEncryption configure file variables
This commit is contained in:
parent
5ac23cd3d6
commit
8469fbd2e8
@ -185,7 +185,6 @@ ChoicePage::init( PartitionCoreModule* core )
|
||||
setModelToComboBox( m_drivesCombo, core->deviceModel() );
|
||||
|
||||
connect( m_drivesCombo, qOverload< int >( &QComboBox::currentIndexChanged ), this, &ChoicePage::applyDeviceChoice );
|
||||
|
||||
connect( m_encryptWidget, &EncryptWidget::stateChanged, this, &ChoicePage::onEncryptWidgetStateChanged );
|
||||
connect( m_reuseHomeCheckBox, &QCheckBox::stateChanged, this, &ChoicePage::onHomeCheckBoxStateChanged );
|
||||
|
||||
@ -469,10 +468,7 @@ ChoicePage::onActionChanged()
|
||||
m_encryptWidget->setFilesystem( FileSystem::typeForName( m_replaceFsTypesChoiceComboBox->currentText() ) );
|
||||
}
|
||||
|
||||
if ( m_config->preCheckEncryption() )
|
||||
{
|
||||
m_encryptWidget->setEncryptionCheckbox( m_config->preCheckEncryption() );
|
||||
}
|
||||
m_encryptWidget->setEncryptionCheckbox( m_config->preCheckEncryption() );
|
||||
}
|
||||
|
||||
Device* currd = selectedDevice();
|
||||
@ -1580,7 +1576,9 @@ ChoicePage::calculateNextEnabled() const
|
||||
}
|
||||
}
|
||||
|
||||
if ( m_config->installChoice() != InstallChoice::Manual && m_encryptWidget->isVisible() )
|
||||
if ( m_config->installChoice() != InstallChoice::Manual
|
||||
&& (m_encryptWidget->isVisible() ||
|
||||
m_encryptWidget->isEncryptionCheckboxChecked()))
|
||||
{
|
||||
switch ( m_encryptWidget->state() )
|
||||
{
|
||||
|
@ -70,6 +70,11 @@ EncryptWidget::EncryptWidget( QWidget* parent )
|
||||
CALAMARES_RETRANSLATE_SLOT( &EncryptWidget::retranslate );
|
||||
}
|
||||
|
||||
bool EncryptWidget::isEncryptionCheckboxChecked()
|
||||
{
|
||||
return m_ui->m_encryptCheckBox->isChecked();
|
||||
}
|
||||
|
||||
void EncryptWidget::setEncryptionCheckbox( bool preCheckEncrypt)
|
||||
{
|
||||
m_ui->m_encryptCheckBox->setChecked( preCheckEncrypt );
|
||||
@ -174,15 +179,10 @@ EncryptWidget::updateState( const bool notify )
|
||||
}
|
||||
}
|
||||
|
||||
Encryption newState = state();
|
||||
|
||||
if ( newState != m_state )
|
||||
m_state = state();
|
||||
if ( notify )
|
||||
{
|
||||
m_state = newState;
|
||||
if ( notify )
|
||||
{
|
||||
Q_EMIT stateChanged( m_state );
|
||||
}
|
||||
Q_EMIT stateChanged( m_state );
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -39,6 +39,7 @@ public:
|
||||
void setEncryptionCheckbox( bool preCheckEncrypt = false);
|
||||
void reset( bool checkVisible = true );
|
||||
|
||||
bool isEncryptionCheckboxChecked();
|
||||
Encryption state() const;
|
||||
void setText( const QString& text );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user