added mouse motion handler