[partition] Polishing, formatting

This commit is contained in:
Adriaan de Groot 2024-04-28 23:07:56 +02:00
parent fd37beae8b
commit e6e46f1ebd
3 changed files with 12 additions and 9 deletions

View File

@ -148,10 +148,10 @@ public:
/// @brief Is manual partitioning allowed (not explicitly disabled in the config file)?
bool allowManualPartitioning() const { return m_allowManualPartitioning; }
/** @brief pre check encryption checkbox.
*
* parameter is used if enableLuksAutomatedPartitioning is true.
* Default value is false
/** @brief Pre-check encryption checkbox.
*
* This is meaningful only if enableLuksAutomatedPartitioning is @c true.
* Default value is @c false
*/
bool preCheckEncryption() const { return m_preCheckEncryption; }

View File

@ -1584,9 +1584,10 @@ ChoicePage::calculateNextEnabled() const
}
}
if ( m_config->installChoice() != InstallChoice::Manual
&& (m_encryptWidget->isVisible() ||
m_encryptWidget->isEncryptionCheckboxChecked()))
// You can have an invisible encryption checkbox, which is
// still checked -- then do the encryption.
if ( m_config->installChoice() != InstallChoice::Manual
&& ( m_encryptWidget->isVisible() || m_encryptWidget->isEncryptionCheckboxChecked() ) )
{
switch ( m_encryptWidget->state() )
{

View File

@ -70,12 +70,14 @@ EncryptWidget::EncryptWidget( QWidget* parent )
CALAMARES_RETRANSLATE_SLOT( &EncryptWidget::retranslate );
}
bool EncryptWidget::isEncryptionCheckboxChecked()
bool
EncryptWidget::isEncryptionCheckboxChecked()
{
return m_ui->m_encryptCheckBox->isChecked();
}
void EncryptWidget::setEncryptionCheckbox( bool preCheckEncrypt)
void
EncryptWidget::setEncryptionCheckbox( bool preCheckEncrypt )
{
m_ui->m_encryptCheckBox->setChecked( preCheckEncrypt );
}