Logo Search packages:      
Sourcecode: qt4-x11 version File versions

void QListView::rowsAboutToBeRemoved ( const QModelIndex parent,
int  start,
int  end 
) [protected, virtual, inherited]

Reimplemented from QAbstractItemView.

Definition at line 761 of file qlistview.cpp.

References QAbstractItemView::rowsAboutToBeRemoved().

{
    Q_D(QListView);
    // if the parent is above d->root in the tree, nothing will happen
    QAbstractItemView::rowsAboutToBeRemoved(parent, start, end);
    if (parent == d->root) {
        int count = (end - start + 1);
        for (int i = d->hiddenRows.count() - 1; i >= 0; --i) {
            if (d->hiddenRows.at(i) >= start) {
                if (d->hiddenRows.at(i) <= end) {
                    d->hiddenRows.remove(i);
                } else {
                    d->hiddenRows[i] -= count;
                }
            }
        }
    }
    d->clear();
    d->doDelayedItemsLayout();
}


Generated by  Doxygen 1.6.0   Back to index