Fix compile with Qt < 5.6

Change-Id: I633d9f85efa709c41ec439f12b8963f612755008
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
This commit is contained in:
Niels Weber
2016-02-16 12:17:41 +01:00
parent 8ac1f8eb29
commit d71e513c96

View File

@@ -299,7 +299,7 @@ void DocSettingsPage::removeDocumentation(const QList<QModelIndex> &items)
m_model->removeAt(row);
}
const int newlySelectedRow = qMax(items.constFirst().row() - 1, 0);
const int newlySelectedRow = qMax(items.first().row() - 1, 0);
const QModelIndex index = m_proxyModel->mapFromSource(m_model->index(newlySelectedRow));
m_ui.docsListView->selectionModel()->select(index, QItemSelectionModel::ClearAndSelect);
}