Commit 3748dc1c authored by hjk's avatar hjk Committed by Eike Ziller
Browse files

QtSupport: Fix crash when inserting from an empty list of examples.



Change-Id: I4dbc796577d77e9bca4e8e76e2f68ada3dd440c0
Reviewed-by: default avatarEike Ziller <eike.ziller@digia.com>
parent 110c31b1
......@@ -455,6 +455,8 @@ void ExamplesListModel::clear()
void ExamplesListModel::addItems(const QList<ExampleItem> &newItems)
{
if (newItems.isEmpty())
return;
beginInsertRows(QModelIndex(), exampleItems.size(), exampleItems.size() - 1 + newItems.size());
exampleItems.append(newItems);
endInsertRows();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment