tags:

views:

77

answers:

1

Hello all.

I'm using QTreeView with QDirModel to list the contents of a directory.. When a user selects an item(or a row) i'm removing it from the tree view using the below method

setRowHidden (self, int, QModelIndex, bool)

How can i know that the tree view is empty or all rows are hidden?? Rowcount and Columncount doesn't seem to help.. Thanks

A: 

You can loop through all items and check if them are hidden with QTreView.isRowHidden(int, QModelIndex).

It is the only way. But why do you hide rows instead of removing them?

Max