ugly fix for an ugly bug, crash on grid view setModel when switching comics views

This commit is contained in:
Luis Ángel San Martín 2015-12-12 15:46:30 +01:00
parent 46ea054d1a
commit 7443ed43be

View File

@ -1325,6 +1325,9 @@ void LibraryWindow::loadLibrary(const QString & name)
void LibraryWindow::loadCoversFromCurrentModel()
{
//TODO this is a workaround for the crash in GridComicsView::setModel crash on views switching
if(typeid(*comicsView) == typeid(GridComicsView))
comicsView->setModel(new ComicModel());
comicsView->setModel(comicsModel);
}