Fixed a crash bug in TextInput