Fix an issue where a text change event is getting posted when it shouldn't be.
Fix a GCC warning.