Release the mouse and capture data at the end of the function. This was not always done before and it was wrong because other event such as mouse left up will not release mouse