|
|
@ -1,7 +1,7 @@
|
|
|
|
/* === This file is part of Calamares - <https://github.com/calamares> ===
|
|
|
|
/* === This file is part of Calamares - <https://github.com/calamares> ===
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* Copyright 2014-2017, Teo Mrnjavac <teo@kde.org>
|
|
|
|
* Copyright 2014-2017, Teo Mrnjavac <teo@kde.org>
|
|
|
|
* Copyright 2017-2018, Adriaan de Groot <groot@kde.org>
|
|
|
|
* Copyright 2017-2019, Adriaan de Groot <groot@kde.org>
|
|
|
|
* Copyright 2019, Collabora Ltd
|
|
|
|
* Copyright 2019, Collabora Ltd
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* Calamares is free software: you can redistribute it and/or modify
|
|
|
|
* Calamares is free software: you can redistribute it and/or modify
|
|
|
@ -100,7 +100,7 @@ ChoicePage::ChoicePage( const SwapChoiceSet& swapChoices, QWidget* parent )
|
|
|
|
, m_eraseButton( nullptr )
|
|
|
|
, m_eraseButton( nullptr )
|
|
|
|
, m_replaceButton( nullptr )
|
|
|
|
, m_replaceButton( nullptr )
|
|
|
|
, m_somethingElseButton( nullptr )
|
|
|
|
, m_somethingElseButton( nullptr )
|
|
|
|
, m_eraseSwapChoices( nullptr )
|
|
|
|
, m_eraseSwapChoiceComboBox( nullptr )
|
|
|
|
, m_deviceInfoWidget( nullptr )
|
|
|
|
, m_deviceInfoWidget( nullptr )
|
|
|
|
, m_beforePartitionBarsView( nullptr )
|
|
|
|
, m_beforePartitionBarsView( nullptr )
|
|
|
|
, m_beforePartitionLabelsView( nullptr )
|
|
|
|
, m_beforePartitionLabelsView( nullptr )
|
|
|
@ -270,8 +270,8 @@ ChoicePage::setupChoices()
|
|
|
|
// .. TODO: only if enabled in the config
|
|
|
|
// .. TODO: only if enabled in the config
|
|
|
|
if ( m_availableSwapChoices.count() > 1 )
|
|
|
|
if ( m_availableSwapChoices.count() > 1 )
|
|
|
|
{
|
|
|
|
{
|
|
|
|
m_eraseSwapChoices = createCombo( m_availableSwapChoices );
|
|
|
|
m_eraseSwapChoiceComboBox = createCombo( m_availableSwapChoices );
|
|
|
|
m_eraseButton->addOptionsComboBox( m_eraseSwapChoices );
|
|
|
|
m_eraseButton->addOptionsComboBox( m_eraseSwapChoiceComboBox );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
m_itemsLayout->addWidget( m_alongsideButton );
|
|
|
|
m_itemsLayout->addWidget( m_alongsideButton );
|
|
|
@ -316,14 +316,14 @@ ChoicePage::setupChoices()
|
|
|
|
|
|
|
|
|
|
|
|
connect( this, &ChoicePage::actionChosen,
|
|
|
|
connect( this, &ChoicePage::actionChosen,
|
|
|
|
this, &ChoicePage::onActionChanged );
|
|
|
|
this, &ChoicePage::onActionChanged );
|
|
|
|
if ( m_eraseSwapChoices )
|
|
|
|
if ( m_eraseSwapChoiceComboBox )
|
|
|
|
connect( m_eraseSwapChoices, QOverload<int>::of(&QComboBox::currentIndexChanged),
|
|
|
|
connect( m_eraseSwapChoiceComboBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
|
|
|
|
this, &ChoicePage::onActionChanged );
|
|
|
|
this, &ChoicePage::onActionChanged );
|
|
|
|
|
|
|
|
|
|
|
|
CALAMARES_RETRANSLATE(
|
|
|
|
CALAMARES_RETRANSLATE(
|
|
|
|
m_somethingElseButton->setText( tr( "<strong>Manual partitioning</strong><br/>"
|
|
|
|
m_somethingElseButton->setText( tr( "<strong>Manual partitioning</strong><br/>"
|
|
|
|
"You can create or resize partitions yourself." ) );
|
|
|
|
"You can create or resize partitions yourself." ) );
|
|
|
|
updateSwapChoicesTr( m_eraseSwapChoices );
|
|
|
|
updateSwapChoicesTr( m_eraseSwapChoiceComboBox );
|
|
|
|
)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -448,7 +448,7 @@ ChoicePage::applyActionChoice( ChoicePage::InstallChoice choice )
|
|
|
|
m_encryptWidget->passphrase(),
|
|
|
|
m_encryptWidget->passphrase(),
|
|
|
|
gs->value( "efiSystemPartition" ).toString(),
|
|
|
|
gs->value( "efiSystemPartition" ).toString(),
|
|
|
|
CalamaresUtils::GiBtoBytes( gs->value( "requiredStorageGB" ).toDouble() ),
|
|
|
|
CalamaresUtils::GiBtoBytes( gs->value( "requiredStorageGB" ).toDouble() ),
|
|
|
|
static_cast<PartitionActions::Choices::SwapChoice>( m_eraseSwapChoices->currentData().toInt() )
|
|
|
|
static_cast<PartitionActions::Choices::SwapChoice>( m_eraseSwapChoiceComboBox->currentData().toInt() )
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
if ( m_core->isDirty() )
|
|
|
|
if ( m_core->isDirty() )
|
|
|
|