TextField dispatchEvent Question

Is there a difference between a user clicking on a TextField and then pressing the space bar and doing something like this in actionscript:

tf.dispatchEvent(new KeyboardEvent(KeyboardEvent.KEY_DOWN, true, false, 32, 32));

… or maybe something like this:

tf.dispatchEvent(new MouseEvent(MouseEvent.CLICK));
tf.dispatchEvent(new KeyboardEvent(KeyboardEvent.KEY_DOWN, true, false, 32, 32));
tf.dispatchEvent(new KeyboardEvent(KeyboardEvent.KEY_UP, true, false, 32, 32));

There seems to be a difference between a user physically keying in the space and trying to duplicate this behavior in code, but I’m not sure what it is. Could someone explain it to me? Also, is there a way to accurately simulate this behavior in code?