mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Check incoming text editing state and only fire textWillChange:, textDidChange:, selectionWillChange:, selectionDidChange: when the text or selection actually changes. On selectionWillChange: in a text field where auto-correct is enabled, iOS will attempt to auto-correct the word preceding the cursor. This change also updates the text before calling selectionWillChange: to prevent auto-correction on the preceding value of the text field.