Basic implementation of input handler.