Description
I have a horizontal scrollview as the first row in a tableView. This scrollview has a click event. The click event works fine on start.
But if I scroll the tableView and the first row (scrollview) scrolls out of the iPad viewport, the click event stops responding.
Steps to Reproduce
1. Create the project with below sample code
2. Run the application
3. Click on first row which is scroll view
Actual result:
Nothing happened
Expected result:
Click event should get fire
Test Case
Ti.UI.backgroundColor = 'white';
var win = Ti.UI.createWindow({
top : 20
});
var table = Ti.UI.createTableView();
var tableData = [];
var row1 = Ti.UI.createTableViewRow({
height : 100,
title : 'row1',
touchEnabled : false
});
var scrollView = Ti.UI.createScrollView({
backgroundColor : 'yellow',
touchEnabled : true,
bubbleParent : true
});
scrollView.addEventListener('click', function() {
Ti.API.info('SV CLICKED');
});
table.addEventListener('click', function(e) {
Ti.API.info('ROW CLICKED' + JSON.stringify(e));
});
var view = Ti.UI.createView({
backgroundColor : '#336699',
borderRadius : 2,
top : 5,
left : 1500,
width : 50,
height : 50
});
view.addEventListener('click', function() {
Titanium.API.info('View Clicked');
});
scrollView.add(view);
row1.add(scrollView);
tableData.push(row1);
for ( i = 2; i <= 10; i++) {
var row = Ti.UI.createTableViewRow({
height : 100,
title : 'row ' + i
});
tableData.push(row);
}
table.setData(tableData);
win.add(table);
win.open();
This is considered unsupported behavior, so a "Won't Fix."
Closing ticket as "Won't Fix".