mirror of
https://github.com/YACReader/yacreader
synced 2025-05-28 03:10:27 -04:00
Fix crash on null pointer
This commit is contained in:
parent
13a29e2657
commit
b1713fc184
@ -300,6 +300,10 @@ void ClassicComicsView::centerComicFlow(const QModelIndex &mi)
|
||||
|
||||
void ClassicComicsView::updateTableView(int i)
|
||||
{
|
||||
if (model == nullptr) {
|
||||
return;
|
||||
}
|
||||
|
||||
QModelIndex mi = model->index(i, 2);
|
||||
tableView->setCurrentIndex(mi);
|
||||
tableView->scrollTo(mi, QAbstractItemView::EnsureVisible);
|
||||
|
Loading…
Reference in New Issue
Block a user