Fix ticket #2269 ([GUI] Crash when rechecking files while having hidden stuff)
If there is no current item show empty details panel.
This commit is contained in:
parent
1a3175741f
commit
9731c736e5
|
@ -277,6 +277,12 @@ void ResultsView::UpdateDetails(const QModelIndex &index)
|
|||
QStandardItemModel *model = qobject_cast<QStandardItemModel*>(mUI.mTree->model());
|
||||
QStandardItem *item = model->itemFromIndex(index);
|
||||
|
||||
if (!item)
|
||||
{
|
||||
mUI.mDetails->setText("");
|
||||
return;
|
||||
}
|
||||
|
||||
// Make sure we are working with the first column
|
||||
if (item->parent() && item->column() != 0)
|
||||
item = item->parent()->child(item->row(), 0);
|
||||
|
|
Loading…
Reference in New Issue