Adds onKeyTyped method