Classified ads
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
ProfileCommentItemDelegate Class Reference

class for displaying single profile comment in a list view More...

#include <profilecommentitemdelegate.h>

Inheritance diagram for ProfileCommentItemDelegate:
Inheritance graph
[legend]
Collaboration diagram for ProfileCommentItemDelegate:
Collaboration graph
[legend]

Public Member Functions

 ProfileCommentItemDelegate (ProfileCommentListingModel &aListingModel, const QWidget &aDrawableWidget, QObject *aParent=NULL)
 
 ~ProfileCommentItemDelegate ()
 

Protected Member Functions

void paint (QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const
 
QSize sizeHint (const QStyleOptionViewItem &option, const QModelIndex &index) const
 

Private Attributes

ProfileCommentListingModeliListingModel
 
const QWidget & iDrawableWidget
 

Detailed Description

class for displaying single profile comment in a list view

Constructor & Destructor Documentation

◆ ProfileCommentItemDelegate()

ProfileCommentItemDelegate::ProfileCommentItemDelegate ( ProfileCommentListingModel aListingModel,
const QWidget &  aDrawableWidget,
QObject *  aParent = NULL 
)

Constructor

Parameters
aListingModelis the datamodel part where content comes from
aDrawableWidgetis the container where these items will be drawn. It is passed here because we want to query its dimensions at runtime.
aParentpossible parent item

◆ ~ProfileCommentItemDelegate()

ProfileCommentItemDelegate::~ProfileCommentItemDelegate ( )

destructor

Member Function Documentation

◆ paint()

void ProfileCommentItemDelegate::paint ( QPainter *  painter,
const QStyleOptionViewItem &  option,
const QModelIndex &  index 
) const
protected

implemented from class QStyledItemDelegate

◆ sizeHint()

QSize ProfileCommentItemDelegate::sizeHint ( const QStyleOptionViewItem &  option,
const QModelIndex &  index 
) const
protected

implemented from class QStyledItemDelegate

Member Data Documentation

◆ iDrawableWidget

const QWidget& ProfileCommentItemDelegate::iDrawableWidget
private

◆ iListingModel

ProfileCommentListingModel& ProfileCommentItemDelegate::iListingModel
private

The documentation for this class was generated from the following file: