Sorry to dig this up, at that time, i were using the first way you told me,
it works fine so i think i will left it like that for a while and come back
after had finished other part. But somehow, i think the eventFilter is not
working at all,
self.GraphicsView.mousePressEvent = self.qView_mousePressEvent
def eventFilter(self, obj, event):
if obj is self.GraphicsView:
if event.button() != QtCore.Qt.LeftButton:
self.qView_mousePressEvent(event)
return True
in the mousePressEvent i had a case when event.button() ==
QtCore.Qt.LeftButton, it will return the QGraphicsView,mousePressEvent. And
if i remove it, the leftMousePressEvent is gone too
I also try install the eventFilter on GraphicsView but no luck :(
http://pastebin.com/SbJfsHTG
On Fri, Mar 1, 2013 at 3:01 AM, Tuan Nguyen <[email protected]> wrote:
> Maybe i had done something funny when reimplement mouseEvent, so the
> result after calling class out still wrong. I will check the script again,
> also thank for show me how to use eventFilter. I try to go with it at first
> place, but since time is short, i chose replace the bounding method instead
> :D
>
> Thank for your reply, Justin
>
--
You received this message because you are subscribed to the Google Groups
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.