Affects Version/s: None
Fix Version/s: Release 8.1.0
Sprint:2019 Sprint 5, 2019 Sprint 6, 2019 Sprint 7, 2019 Sprint 8, 2019 Sprint 9, 2019 Sprint 10, 2019 Sprint 11, 2019 Sprint 12, 2019 Sprint 13, 2019 Sprint 14, 2019 Sprint 15
Entering text into a TextField/TextArea embedded within a TableView can cause performance issues if the virtual keyboard shows/hides its top suggestion bar dynamically. It can also cause the cursor to suddenly move to the end of field and cause the field to flicker.
By default, the "windowSoftInputMode" is set to Ti.UI.Android.SOFT_INPUT_ADJUST_PAN (aka: "adjustPan"), which means that showing/hiding the virtual keyboards will cause the window to resize. The resizing of a TableView triggers its row recycling/update behavior which can cause the "contents" of each row (such as the TextField) to be re-parented to a new row container view, which causes havoc with the virtual keyboard.
For virtual keyboards that have a fixed height and do not pop-in/out a suggestion bar as you type, this isn't really an issue since the above mentioned resize behavior happens once. For example, this is not an issue on a Pixel phone.
But some device pop-in/out a suggestion bar as you type which causes the TableView to resize every time you type in a character. This will cause massive performance issues.
Steps to reproduce:
- Build and run TableOfTextFieldsTest.js on Android.
- Tap on row 1's TextArea.
- Notice that the cursor is moved to end of the field. (The code is supposed to highlight the whole text instead.)
- Notice the below warnings get logged.
Set up the window to "adjustPan". This works-around the issue because it causes the virtual keyboard to be overlaid on top of the window instead of resizing it, which avoids the issue.
Use a ScrollView instead of a TableView.