Try to invalidate whole PartitionModel on replace.
This commit is contained in:
parent
2a61114d9e
commit
9847b8efa9
@ -239,3 +239,10 @@ PartitionModel::partitionForIndex( const QModelIndex& index ) const
|
||||
return nullptr;
|
||||
return reinterpret_cast< Partition* >( index.internalPointer() );
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
PartitionModel::update()
|
||||
{
|
||||
emit dataChanged( index( 0, 0 ), index( rowCount() - 1, columnCount() - 1 ) );
|
||||
}
|
||||
|
@ -110,6 +110,8 @@ public:
|
||||
return m_device;
|
||||
}
|
||||
|
||||
void update();
|
||||
|
||||
private:
|
||||
Device* m_device;
|
||||
OsproberEntryList m_osproberEntries;
|
||||
|
@ -444,6 +444,9 @@ ChoicePage::applyActionChoice( ChoicePage::Choice choice )
|
||||
PartitionActions::doReplacePartition( m_core,
|
||||
selectedDevice(),
|
||||
partition );
|
||||
PartitionModel* m = qobject_cast< PartitionModel* >( m_afterPartitionBarsView->model() );
|
||||
if ( m )
|
||||
m->update();
|
||||
};
|
||||
|
||||
if ( m_core->isDirty() )
|
||||
|
Loading…
Reference in New Issue
Block a user