[partition] Refactor slot for change in action
- Let's not go overboard on lambdas, - Needed for others that also want to update the partitioning preview
This commit is contained in:
parent
b8595a1323
commit
0231619c7c
@ -305,14 +305,7 @@ ChoicePage::setupChoices()
|
||||
m_rightLayout->setStretchFactor( m_previewAfterFrame, 0 );
|
||||
|
||||
connect( this, &ChoicePage::actionChosen,
|
||||
this, [=]
|
||||
{
|
||||
Device* currd = selectedDevice();
|
||||
if ( currd )
|
||||
{
|
||||
applyActionChoice( currentChoice() );
|
||||
}
|
||||
} );
|
||||
this, &ChoicePage::onActionChanged );
|
||||
|
||||
CALAMARES_RETRANSLATE(
|
||||
updateSwapChoicesTr( m_eraseSwapChoices );
|
||||
@ -412,6 +405,17 @@ ChoicePage::continueApplyDeviceChoice()
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
ChoicePage::onActionChanged()
|
||||
{
|
||||
Device* currd = selectedDevice();
|
||||
if ( currd )
|
||||
{
|
||||
applyActionChoice( currentChoice() );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
ChoicePage::applyActionChoice( ChoicePage::InstallChoice choice )
|
||||
{
|
||||
|
@ -109,6 +109,9 @@ private slots:
|
||||
void onEncryptWidgetStateChanged();
|
||||
void onHomeCheckBoxStateChanged();
|
||||
|
||||
/** @brief Calls applyActionChoice() as needed. */
|
||||
void onActionChanged();
|
||||
|
||||
private:
|
||||
void updateNextEnabled();
|
||||
void setupChoices();
|
||||
|
Loading…
Reference in New Issue
Block a user