added inputButtonJustUp functionality