diff options
Diffstat (limited to 'Swift/QtUI/UserSearch/ContactListDelegate.cpp')
| -rw-r--r-- | Swift/QtUI/UserSearch/ContactListDelegate.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Swift/QtUI/UserSearch/ContactListDelegate.cpp b/Swift/QtUI/UserSearch/ContactListDelegate.cpp index 29cab83..56c479b 100644 --- a/Swift/QtUI/UserSearch/ContactListDelegate.cpp +++ b/Swift/QtUI/UserSearch/ContactListDelegate.cpp @@ -5,4 +5,10 @@ */ +/* + * Copyright (c) 2014 Kevin Smith and Remko Tronçon + * Licensed under the GNU General Public License v3. + * See Documentation/Licenses/GPLv3.txt for more information. + */ + #include <Swift/QtUI/UserSearch/ContactListDelegate.h> #include <Swift/QtUI/UserSearch/ContactListModel.h> @@ -22,5 +28,5 @@ void ContactListDelegate::paint(QPainter* painter, const QStyleOptionViewItem& o return; } - const Contact* contact = static_cast<Contact*>(index.internalPointer()); + const Contact::ref contact = static_cast<Contact*>(index.internalPointer())->shared_from_this(); QColor nameColor = index.data(Qt::TextColorRole).value<QColor>(); QString avatarPath = index.data(ContactListModel::AvatarRole).value<QString>(); |
Swift