Hello,

does anybody have experience in gesture programming with PyQt? I am trying to 
program a custom gesture recognizer, but registering it with 
QGestureRecognizer.registerRecognizer(…) crashes the script. Here is the 
excerpt of the code that is executing the above function.

--CODE--
class E5SwipeGestureRecognizer(QGestureRecognizer):
   __type = 0
   __instance = None

   def __init__(self):
       super().__init__()

   @classmethod
   def gestureType(cls):
       if cls.__instance is None:
           cls.__instance = E5SwipeGestureRecognizer()
           cls.__type = QGestureRecognizer.registerRecognizer(cls.__instance)
       return cls.__type
--END CODE--


Regards,
Detlev


Detlev Offenbach
det...@die-offenbachs.de



Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

_______________________________________________
PyQt mailing list    PyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Reply via email to