Keep an immutable copy for every scanned Device* to avoid rescans.

This commit is contained in:
Teo Mrnjavac 2016-09-09 11:25:04 +02:00
parent 464336d609
commit c316d22b08
3 changed files with 20 additions and 15 deletions

View file

@ -813,7 +813,7 @@ ChoicePage::updateDeviceStatePreview()
m_beforePartitionLabelsView = new PartitionLabelsView( m_previewBeforeFrame );
m_beforePartitionLabelsView->setExtendedPartitionHidden( mode == PartitionBarsView::NoNestedPartitions );
Device* deviceBefore = m_core->createImmutableDeviceCopy( currentDevice );
Device* deviceBefore = m_core->immutableDeviceCopy( currentDevice );
PartitionModel* model = new PartitionModel( m_beforePartitionBarsView );
model->init( deviceBefore, m_core->osproberEntries() );