fixed mouse bug in input thread