diff options
author | Arno <am@disconnect.de> | 2011-12-28 19:36:05 +0100 |
---|---|---|
committer | Arno <am@disconnect.de> | 2011-12-28 19:36:05 +0100 |
commit | 83d2b014f563b9de387c4d8e9e45adbb36b56825 (patch) | |
tree | 09174bbb145df0967dfe4cd11c0cd829b36db51e /smtreeitem.cpp | |
parent | a18c569e6ffaea7a8a4f387b1c1e4245146e29d8 (diff) | |
download | SheMov-83d2b014f563b9de387c4d8e9e45adbb36b56825.tar.gz SheMov-83d2b014f563b9de387c4d8e9e45adbb36b56825.tar.bz2 SheMov-83d2b014f563b9de387c4d8e9e45adbb36b56825.zip |
Mark items in DbAnalyzerDialog
It's now possible to mark items in DbAnalyzerDialog with a different
color, when there are no covers or actor information available on the
net. I enhanced SmTreeItem to contain a QVariant::foregroundColor, and
made SmTreeModel return it when QModelIndex::data with role
Qt::ForegroundRole is called. Maybe that could be useful for other
things like favorites and such...
Diffstat (limited to 'smtreeitem.cpp')
-rw-r--r-- | smtreeitem.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/smtreeitem.cpp b/smtreeitem.cpp index 5584319..56d9b6e 100644 --- a/smtreeitem.cpp +++ b/smtreeitem.cpp @@ -73,6 +73,14 @@ void SmTreeItem::setData(int column, const QVariant &data){ mData[column] = data; } +QVariant SmTreeItem::foregroundColor() const{ + return mForegroundColor; +} + +void SmTreeItem::setForegroundColor(const QVariant &data){ + mForegroundColor = data; +} + bool SmTreeItem::insertChild(int where, SmTreeItem *child){ if((where < 0) || (where > mChildren.count())){ return false; |