Evaluating key codes with switch vs if statements

