Commit e20dab61 authored by T.J. Corona's avatar T.J. Corona

qtCheckItemComboBox: force update when internal model has changed.

parent fb8e8dc7
......@@ -215,6 +215,13 @@ void qtModelEntityItemCombo::init()
}
}
itemModel->sort(0);
// the internal item model for our combo box has changed. For some reason,
// the appropriate signals do not fire to trigger the view to update unless
// we remove and add the item model to the view.
this->view()->setModel(nullptr);
this->view()->setModel(itemModel);
this->view()->viewport()->update();
}
connect(this->model(), SIGNAL(dataChanged(const QModelIndex&, const QModelIndex&)), this,
SLOT(itemCheckChanged(const QModelIndex&, const QModelIndex&)));
......
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