invalidate the page filter proxy model less times

svn path=/trunk/KDE/kdegraphics/okular/; revision=710549
remotes/origin/KDE/4.0
Pino Toscano 19 years ago
parent c70cb99bdc
commit 5da8a9861e
  1. 8
      ui/annotationproxymodels.cpp

@ -32,8 +32,6 @@ void PageFilterProxyModel::groupByCurrentPage( bool value )
mGroupByCurrentPage = value;
invalidateFilter();
emit layoutChanged();
}
void PageFilterProxyModel::setCurrentPage( int page )
@ -43,9 +41,11 @@ void PageFilterProxyModel::setCurrentPage( int page )
mCurrentPage = page;
invalidateFilter();
// no need to invalidate when we're not showing the current page only
if ( !mGroupByCurrentPage )
return;
emit layoutChanged();
invalidateFilter();
}
bool PageFilterProxyModel::filterAcceptsRow( int row, const QModelIndex &sourceParent ) const

Loading…
Cancel
Save