fixed StyledDelegates and added proxymodel to lists model

This commit is contained in:
Luis Ángel San Martín
2014-11-20 23:15:05 +01:00
parent 58765649c2
commit 5f75d278d4
12 changed files with 92 additions and 30 deletions

View File

@ -87,10 +87,8 @@ YACReaderFoldersViewItemDeletegate::YACReaderFoldersViewItemDeletegate(QObject *
void YACReaderFoldersViewItemDeletegate::paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const
{
/*
FolderItem * item = static_cast<FolderItem *>(index.internalPointer());
if(!item->data(FolderModel::Completed).toBool())
if(index.data(FolderModel::CompletedRole).toBool())
{
painter->save();
#ifdef Q_OS_MAC
@ -102,6 +100,6 @@ void YACReaderFoldersViewItemDeletegate::paint(QPainter *painter, const QStyleOp
painter->drawRect(0,option.rect.y(),2,option.rect.height());
painter->restore();
}
*/
QStyledItemDelegate::paint(painter, option, index);
}