added mouse functionality