Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-28557] Android: ListView visibility change may not display items

GitHub Issuen/a
TypeImprovement
PriorityMedium
StatusClosed
ResolutionFixed
Resolution Date2021-10-20T02:46:44.000+0000
Affected Version/sn/a
Fix Version/sRelease 10.2.0
ComponentsAndroid
Labelsn/a
ReporterGary Mathews
AssigneeGary Mathews
Created2021-10-15T18:30:50.000+0000
Updated2021-10-20T02:46:44.000+0000

Description

- ListView.show() and ListView.visibility may not display list items under certain criterias *TEST CASE*
const window = Ti.UI.createWindow();
const listView = Ti.UI.createListView({
	visible: false, // Set visible equal to true and I work
	searchView: Ti.UI.createSearchBar() // Remove the searchView and I work
});
// Comment out the event listener and I work, change me to 'click' and still broke though
window.addEventListener('open', () => {
	const data = []
	for (let i = 0; i < 5; i++) {
		const row = {
			properties: {
				title: Foo ${i},
				color: "#000000",
				backgroundColor: "#FFFFFF",
				height: 50
			}
		}
		const section = Ti.UI.createListSection({
			headerTitle: Test ${i},
			items: [ row ]
		});
		data.push(section);
	}
	listView.sections = data;
        // listView.visibility = true;
	listView.show();
});
window.add(listView)
window.open();

Comments

  1. Gary Mathews 2021-10-15

    master: https://github.com/appcelerator/titanium_mobile/pull/13124

JSON Source