mouse: fix ghost touch that can appear on window (due to a race condition between mousemotion / mouserelease). closes #621

This commit is contained in:
Mathieu Virbel 2012-08-10 11:17:54 +02:00
parent 5d6b2166fb
commit f747e0d6cb
1 changed files with 1 additions and 4 deletions

View File

@ -206,10 +206,7 @@ class MouseMotionEventProvider(MotionEventProvider):
self.remove_touch(cur)
self.current_drag = None
width, height = EventLoop.window.system_size
rx = x / float(width)
ry = 1. - y / float(height)
cur = self.find_touch(rx, ry)
cur = self.current_drag
if (button in ('left', 'scrollup', 'scrolldown') or
self.disable_multitouch) and cur and not ('ctrl' in modifiers):
self.remove_touch(cur)