added mouse direction switch