Hi, i was doing a little game and when using a QGraphicsRectItem with the mousePressEvent i tried to capture the event where the player clicks both left and right click, i've tried the following without luck:<br><br>def mousePressEvent(self, event):
<br> print event.button() # prints 1<br> print QtCore.Qt.RightButton # prints 2<br> print QtCore.Qt.LeftButton # prints 1<br> print event.buttons().__int__() # always the same as button()
<br> print event.buttons().__int__() & QtCore.Qt.RightButton & QtCore.Qt.LeftButton # Always false, no wonder seeing the line before :P<br><br><br>Best Regards<br>Hernan Rajchert<br>