diff options
Diffstat (limited to 'src/qgraphicslistview.cpp')
-rw-r--r-- | src/qgraphicslistview.cpp | 29 |
1 files changed, 26 insertions, 3 deletions
diff --git a/src/qgraphicslistview.cpp b/src/qgraphicslistview.cpp index 0ffd73b..06cd98e 100644 --- a/src/qgraphicslistview.cpp +++ b/src/qgraphicslistview.cpp @@ -206,6 +206,7 @@ QtGraphicsListView *QtGraphicsListViewItem::view() const */ /*! + Destructor. */ QtGraphicsListViewItemCreatorBase::~QtGraphicsListViewItemCreatorBase() { @@ -216,7 +217,8 @@ QtGraphicsListViewItemCreatorBase::~QtGraphicsListViewItemCreatorBase() */ /*! - */ + This method basically does a recycle and a create in one go. +*/ QtGraphicsListViewItem *QtGraphicsListViewItemCreatorBase::reassign(int index, QtGraphicsListViewItem *item) { Q_ASSERT(item); @@ -225,15 +227,26 @@ QtGraphicsListViewItem *QtGraphicsListViewItemCreatorBase::reassign(int index, Q } /*! - */ + Give back the \a item to the creator pool of unused objects. +*/ void QtGraphicsListViewItemCreatorBase::recycle(QtGraphicsListViewItem *item) { delete item; } /*! + \fn QtGraphicsListViewItem *QtGraphicsListViewItemCreatorBase::create(int index, QtGraphicsListView *view) + The view will call the create() method for every visible item it needs to display on screen. + This is a factory method to create the item, or reuse a previously recycled one after which + the ownership of the item lies with the caller. + + The item will be initialized to belong to \a view and will get the \a index set to it + allowing it to show the correct content. +*/ + +/*! \class QtGraphicsListViewItemCreator - */ +*/ // QtGraphicsListViewPrivate @@ -1278,4 +1291,14 @@ void QtGraphicsListView::itemGeometryChanged(QtGraphicsListViewItem *item) } } +/*! + \class QtGraphicsListViewItemCreatorBase + \brief a factory baseclass to create QtGraphicsListViewItem objects for the QtGraphicsListView +*/ + +/*! + \class QtGraphicsListViewItemCreator + \brief a easy to use factory class to create QtGraphicsListViewItem objects for the QtGraphicsListView +*/ + #include "moc_qgraphicslistview.cpp" |