Is there a better way of creating a contextMenu (a small menu when you right click) inside a QTreeWidget<br>than setting the setContextMenuPolicy? This is what I currently do:<br><br>self.treeView = QTreeWidget()<br>self.treeView.setContextMenuPolicy
(Qt.CustomContextMenu)<br>self.connect(self.treeView,SIGNAL('customContextMenuRequested(QPoint)'),self.newContext)<br><br>But, the problem I'm having is that the right click to bring up the menu, also changes the selection.
<br>How can I tell the tree to ignore right clicks but still bring up the contextmenu? Oh, and as a side<br>question. How can I get a list of the QTreeWidgetItems that make up the tree? I saw items() but I<br>didn't quite understand how to set the QMimeData type (I'm sorry, I'm a bit new to QT :( ) Thank you!