ScrollView
doesn't return correct source when event listener is added to the scroll view's parent.
var win = Ti.UI.createWindow({
backgroundColor: 'green',
width: 800,
height: 600
});
var view = Ti.UI.createView({
backgroundColor: 'red',
width: '80%',
height: '80%',
id: 'view'
}),
view2 = Ti.UI.createScrollView({
width: '70%', height: '70%', backgroundColor: 'blue', id: 'view2'
}),
view3 = Ti.UI.createView({
width: '70%', height: '70%', backgroundColor: 'pink', id: 'view3'
});
view2.add(view3);
view.add(view2);
view.addEventListener('click', function (e) {
alert(e.source.id);
});
win.add(view);
win.open();
Expected: When blue view is clicked, it should show "view2".
https://github.com/appcelerator/titanium_mobile_windows/pull/1260 https://github.com/appcelerator/titanium_mobile_windows/pull/1261
*Closing ticket.* Verified fix in SDK Version
7.3.0.v20180627164434
and SDK version7.4.0.v20180628005853
*FR Passed*Created an application with the code in the description
Ran the program
Pressed the blue square
'view 2' was returned
Pressed the pink view
'view 3' was returned
*Test Environment*