[TIMOB-5789] iOS: setting the 'hasCheck' property of TableViewRow causes the child elements added to the row to disappear
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Cannot Reproduce |
Resolution Date | 2012-02-10T00:29:00.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | iOS |
Labels | n/a |
Reporter | Sandeep Bhimavarapu |
Assignee | Stephen Tramer |
Created | 2011-10-17T15:01:05.000+0000 |
Updated | 2012-02-10T00:29:00.000+0000 |
Description
Setting the 'hasCheck' property on the row's click event causes the child elements of the row to disappear. This appears to happen with the newer CI builds. Also, the elements do not disappear at the time of click event. When another row is clicked, the elements on the previously clicked row disappear.
When checked with the CI build 1.8.0.v20111008193843, the problem does not appear.
Sample Code:
{noformat}
var win = Ti.UI.createWindow({backgroundColor: 'white'});
var section1 = Ti.UI.createTableViewSection({
headerTitle:'Header 1'
});
var createRow = function(name){
var row = Ti.UI.createTableViewRow();
row.add(Ti.UI.createLabel({color: 'green', text:'Row '+ name,height: 30, top:5, width: 80, left: 10}));
row.add(Ti.UI.createImageView({ image: 'KS_nav_views.png',height: 30, top:5, width: 80, right: 40}));
row.addEventListener('click', function(e){
row.hasCheck = true;
});
return row;
}
for (var i=0; i < 4; i++) {
section1.add(createRow(i));
}
var section2 = Ti.UI.createTableViewSection();
for (var i=4; i < 10; i++) {
section2.add(createRow(i));
}
var tv = Ti.UI.createTableView({
data:[section1,section2]
});
win.add(tv);
win.open();
{noformat}
Unable to reproduce in 1.9.0.46d2d6f.
Closing issue due to not being able to reproduce Tested with Ti Studio 1.0.8.201201101928 Ti Mob SDK 1.8.0.1 OSX Lion iPod Touch OS 4.3.3, iPad 2 OS 5.0.1