As others have mentioned, you'll need to look into your endMove
handler and clean up the logic there.
However, simply removing the handler isn't quite the answer (since you'll find yourself with a "jerky" experience if you continue mousing around).
Here are two things I would recommend (with a fiddle: http://jsfiddle.net/uUbRy/)
Capture the element that has focus.
In mouseDown
, I set elementWithFocus = evt.target
to use in your mousemove handler.
Address the endMove issue.
For that, I've updated your handler with the following condition check:
if(evt.type == 'mouseout' && click) {
return;
}