PySide Bugzilla Closed for New Bugs

PySide is now a Qt Add-on and uses the Qt Project's JIRA Bug Tracker instead of this Bugzilla instance. This Bugzilla is left for reference purposes.

Bug 112 - QTreeView.setModel with QDirModel
: QTreeView.setModel with QDirModel
Status: CLOSED WORKSFORME
Product: PySide
Classification: Unclassified
Component: PySide
: HEAD
: All All
: P2 major
Assigned To: renato filho
:
:
:
  Show dependency treegraph
 
Reported: 2009-12-28 10:39 EET by Hugo Parente Lima
Modified: 2010-04-07 11:09 EEST (History)
6 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hugo Parente Lima 2009-12-28 10:39:27 EET
from PySide mailing list (regomodo <regomodo googlemail.com>):

In my PyQt4 app it uses a QTreeView which I then change it's model to 
QDirModel by using QTreeView.setModel.

However, in the pyside docs I see that this function is missing 

http://www.pyside.org/docs/pyside/PySide/QtGui/QTreeView.html

Is this function enabled as I get errors with this code snippet:

        self.dir_model = QDirModel()
        filters = QDir.Files | QDir.AllDirs | QDir.Readable | 
QDir.NoDotAndDotDot
        self.dir_model.setFilter(filters)
        self.dir_model.setReadOnly(True)
        self.dir_model.setNameFilters(["*.ogg", "*.flac", "*.mp3",  "*.m4a"])
        self.ui.fileView.setModel(self.dir_model) 

The error(from Eric ide):

The debugged program raised the exception unhandled ArgumentError
"Python argument types in QTreeView.setModel(QTreeView, QDirModel) did not 
match C++ signature: setModel(QTreeView {lvalue}, QAbstractItemModel*)"
Comment 1 Lauro Moura 2010-01-09 17:06:57 EET
Renato tested and asked the OP to verifiy if this bug is still valid, as we
couldn't reproduce from current code. It has been 12 days without answer.

Maybe we could mark as invalid.
Comment 2 Luciano Wolf 2010-01-26 14:46:54 EET
Long time without answers from the user.