The PartitionModel should be owned by the PCM.

This commit is contained in:
Teo Mrnjavac 2015-12-17 19:10:47 +01:00
parent 4859431fe9
commit 275b68cf5c

View File

@ -574,8 +574,7 @@ ChoicePage::updateActionChoicePreview( ChoicePage::Choice choice )
previewLabels->setCustomNewRootLabel( Calamares::Branding::instance()->
string( Calamares::Branding::BootloaderEntryName ) );
PartitionModel* model = new PartitionModel( preview );
model->init( currentDevice, m_core->osproberEntries() );
PartitionModel* model = m_core->partitionModelForDevice( selectedDevice() );
// The QObject parents tree is meaningful for memory management here,
// see qDeleteAll above.