02-24-2014 05:04 PM - edited 02-24-2014 05:09 PM
I can also reproduce this by simply setting stage.focus to the TextField:
var text:TextField = new TextField();
text.type = TextFieldType.INPUT;
stage.focus = text; //APP CRASHES HERE
02-24-2014 05:47 PM - edited 02-25-2014 01:15 AM
This seems to require several workarounds, I've put it into a class here:
02-26-2014 01:12 AM
Thanks for identify and resolving the problem.
I found this prevents the crash when setting focus:
var tf : Textfield = new Textfield();
tf.text = " ";
tf.setSelection(tf.length, tf.length); // set cursor at end of text (after the space)
stage.focus = tf;
The text field cursor somehow causes the crash when it's at position 0.