Moved to mouseup event.
Fixed issue with double-clicking not working.