diff options
author | Kevin Smith <git@kismith.co.uk> | 2009-07-26 19:17:46 (GMT) |
---|---|---|
committer | Kevin Smith <git@kismith.co.uk> | 2009-07-26 19:17:46 (GMT) |
commit | 46e59e0e6bfceee216db3414680825cbdae60daf (patch) | |
tree | d1e078bb0eec292d628e7d44fccc8345ecc1d911 /Swift/QtUI/Roster/RosterDelegate.cpp | |
parent | ce74ccc7c8d2ce4c032a90b1ebc0ebd30b4ea4c8 (diff) | |
download | swift-contrib-46e59e0e6bfceee216db3414680825cbdae60daf.zip swift-contrib-46e59e0e6bfceee216db3414680825cbdae60daf.tar.bz2 |
Use a (boring) delegate for roster rendering.
Diffstat (limited to 'Swift/QtUI/Roster/RosterDelegate.cpp')
-rw-r--r-- | Swift/QtUI/Roster/RosterDelegate.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Swift/QtUI/Roster/RosterDelegate.cpp b/Swift/QtUI/Roster/RosterDelegate.cpp index e69de29..925f66c 100644 --- a/Swift/QtUI/Roster/RosterDelegate.cpp +++ b/Swift/QtUI/Roster/RosterDelegate.cpp @@ -0,0 +1,16 @@ +#include "RosterDelegate.h" + +#include <QPainter> + +namespace Swift { +QSize RosterDelegate::sizeHint(const QStyleOptionViewItem& option, const QModelIndex& index ) const { + return QSize(100,50); +} + +void RosterDelegate::paint(QPainter* painter, const QStyleOptionViewItem& option, const QModelIndex index) const { + painter->save(); + QStyledItemDelegate::paint(painter, option, index); + painter->restore(); +} + +}
\ No newline at end of file |