If you need a model that represents the file system, have a look at QFileSystemModel

Cheers,
_