EngoEngine / engo

Engo is an open-source 2D game engine written in Go.
https://engoengine.github.io
MIT License
1.74k stars 136 forks source link

Fixed missed case in setting Dragged flag #703

Closed m0re4u closed 4 years ago

m0re4u commented 4 years ago

Missed a case when fixing the Dragged flag for the mouse. In this case, the mouse was Clicked but unmoved, which would register both as a click and a drag. With this fix, if the mouse is pressed down and stays in the same place, it is considered to be Clicked. If it moves at some point while still pressed, the mouse will be Dragged as long as there is no mouse release.

Noofbiz commented 4 years ago

Awesome thanks for the catch. Could probably use this to clean up the mouse demos down the road.