[TIMOB-25223] Android: ListView in front of other views (wrong z-order)
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2017-09-07T01:22:20.000+0000 |
Affected Version/s | Release 6.2.0 |
Fix Version/s | Release 6.2.0 |
Components | n/a |
Labels | android, automated, listview, regression |
Reporter | Michael Gangolf |
Assignee | Gary Mathews |
Created | 2017-09-01T15:56:27.000+0000 |
Updated | 2017-09-15T23:15:40.000+0000 |
Description
*Summary:*
When creating a ListView and adding a loading indicator (view + ActivitiyIndicator) after the ListView, the loading indicator is not visible with 6.2.0.RC
*Code:*
var win = Ti.UI.createWindow({
backgroundColor: 'gray'
}),
list = Ti.UI.createListView({
separatorColor: "transparent",
templates: {
template: {
childTemplates: [{
type: 'Ti.UI.View',
bindId: 'item',
properties: {
top: '5dp',
bottom: '5dp',
width: '200dp',
height: '50dp',
borderWidth: '8dp',
backgroundColor: 'green'
}
}]
}
},
defaultItemTemplate: 'template'
}),
section = Ti.UI.createListSection(),
items = [];
for (var i = 0; i < 24; i++) {
var colour = i % 2 ? 'green' : 'yellow';
items.push({
item: {
backgroundColor: colour,
borderColor: colour
}
});
}
section.setItems(items);
list.setSections([section]);
win.add(list);
var fgview = Ti.UI.createView({
width: Ti.UI.FILL,
height: Ti.UI.FILL,
backgroundColor: "rgba(0,0,0,0.5)"
});
var act = Ti.UI.createActivityIndicator({});
fgview.add(act);
win.add(fgview);
act.show();
win.open();
*Results:*
6.1.2.GA: Black View + ActivityIndicator shown in front of the ListView
6.2.0.RC: ListView stays in front; black view + ActivityIndicator not visible
It's not just related to
ActivityIndicator
, it's related to theheight
of the view. It seemsTi.UI.FILL
is not being calculated correctly? *TEST CASE*-master-: https://github.com/appcelerator/titanium_mobile/pull/9397 -6_2_X-: https://github.com/appcelerator/titanium_mobile/pull/9396
Continued by: master: https://github.com/appcelerator/titanium_mobile/pull/9403 6_2_X: https://github.com/appcelerator/titanium_mobile/pull/9404
FR Passed. PR's merged.
Verified the fix in SDK 6.2.0.v20170907070223 & 7.0.0.v20170907070720. Closing. Studio Ver: 4.9.1.201707200100 OS Ver: 10.12.3 Xcode Ver: Xcode 8.3.3 Appc NPM: 4.2.9 Appc CLI: 6.2.4-9 Ti CLI Ver: 5.0.14 Alloy Ver: 1.9.13 Node Ver: 6.11.2 Java Ver: 1.8.0_101 Devices: ⇨ google Nexus 5 — Android 6.0.1 ⇨ google Pixel — Android 7.1.1