py: drop the fancy event handling
[android/external-libkmsxx.git] / py / tests / sync.py
index 4616ee85a977a7c5e3a709214ccc489b160a23c1..e394c8d3d7664347aac76f48597d0ea3450659b1 100755 (executable)
@@ -148,7 +148,7 @@ class FlipHandler():
         fence = self.timeline.create_fence(2 * self.flips - 1)
         req = pykms.AtomicReq(self.crtc.card)
         req.add(self.crtc.primary_plane, { 'FB_ID': fb.id, 'IN_FENCE_FD': fence.fd })
-        req.commit(self)
+        req.commit()
         del fence
 
         # Arm a timer to signal the fence in 0.5s.
@@ -207,7 +207,7 @@ def main(argv):
     def readdrm(fileobj, mask):
         for ev in card.read_events():
             if ev.type == pykms.DrmEventType.FLIP_COMPLETE:
-                ev.data.handle_page_flip(ev.seq, ev.time)
+                flip_handler.handle_page_flip(ev.seq, ev.time)
 
     def readkey(fileobj, mask):
         sys.stdin.readline()