[TIMOB-14693] BlackBerry: No header text on TableViewSection
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2014-06-05T19:51:27.000+0000 |
Affected Version/s | Release 3.1.2 |
Fix Version/s | 2013 Sprint 16, 2013 Sprint 16 API, Release 3.3.0 |
Components | BlackBerry |
Labels | qe-3.3.0, qe-closed-3.1.2, qe-nfc, qe-port, qe-testadded, sdk-bb |
Reporter | Lokesh Choudhary |
Assignee | Pedro Enrique |
Created | 2013-07-30T00:21:34.000+0000 |
Updated | 2014-06-17T23:33:25.000+0000 |
Description
Description:
1. Create a BB app with the following code:
Titanium.UI.setBackgroundColor('#000');
var tabGroup = Titanium.UI.createTabGroup();
var win1 = Titanium.UI.createWindow({
title:'Test 1',
backgroundColor:'#fff'
});
var tab1 = Titanium.UI.createTab({
icon:'KS_nav_views.png',
title:'Test 1',
window:win1
});
var table = Ti.UI.createTableView({
width: Ti.UI.FILL,
height: Ti.UI.FILL,
data: [
{title: 'row 1', header: 'section 1', subHeader: 'sub header of section 1'},
{title: 'row 2'},
{title: 'row 3'},
{title: 'row 4'},
{title: 'row 5'},
{title: 'row 1', header: 'section 2'},
{title: 'row 2'},
{title: 'row 3'},
{title: 'row 4'},
{title: 'row 5'},
{title: 'row 1', header: 'section 3'},
{title: 'row 2'},
{title: 'row 3'},
{title: 'row 4'},
{title: 'row 5'},
{title: 'row 1', header: 'section 4', subHeader: 'sub header of section 4'},
{title: 'row 2'},
{title: 'row 3'},
{title: 'row 4'},
{title: 'row 5'},
{title: 'row 1', header: 'section 5'},
{title: 'row 2'},
{title: 'row 3'},
{title: 'row 4'},
{title: 'row 5'}
]
});
win1.add(table);
var win2 = Titanium.UI.createWindow({
title:'Test 2',
backgroundColor:'#fff'
});
var tab2 = Titanium.UI.createTab({
icon:'KS_nav_ui.png',
title:'Test 2',
window:win2
});
var d = [];
for(var i = 0; i < 10; i++) {
var section = Ti.UI.createTableViewSection({
title: 'Hello section number ' + i,
subTitle: 'This is a subtitle for section #' + i
});
for(var a = 0; a < 10; a++) {
section.add(Ti.UI.createTableViewRow({
title: 'Section #' + i + ' Row #' + a
}));
}
d.push(section);
}
var table1 = Ti.UI.createTableView({
width: Ti.UI.FILL,
height: Ti.UI.FILL,
data: d
});
win2.add(table1);
tabGroup.addTab(tab1);
tabGroup.addTab(tab2);
tabGroup.open();
2. Build & run on BB device/simulator
3. Go To test 2 tab.
4. Look at the header for sections
Actual result:
1. We do not see the headers for sections instead we get header same as the subTitle.
This happens only for Ti.UI.createTableViewSection not for Ti.UI.createTableView
We see this behaviour for alloy apps too.
PR: https://github.com/appcelerator/titanium_mobile_blackberry/pull/140
Verified fixed with the provided classic project sample in the description. Alloy sample project
Titanium SDK 3.1.2.v20130808180613 Alloy 1.2.0-alpha6 Appcelerator Studio 3.1.2.201308071912 CLI 3.1.2-alpha Node 0.10.13 Closing.
Verified fixed on: Mac OSX 10.9 Mavericks Titanium Studio, build: 3.2.0.201311122225 Titanium SDK, build: 3.2.0.v20131113094843 CLI: 3.2.0 Alloy: 1.3.0 BlackBerry Simulator: 10.2.0.1791 Code from description and code provided by Federico. Table view shows header text, subheader text and tablerow text. Closing.
Tested with: Mac osx 10.9.3 Mavericks Appcelerator Studio, build: 3.3.0.201405271647 Titanium SDK, build: 3.3.0.v20140603032057 Node.JS Version: v0.10.13 NPM Version: 1.3.2 acs@1.0.14 alloy@1.4.0-beta npm@1.3.2 titanium@3.3.0-beta2 titanium-code-processor@1.1.1 Device: BB Z10 (10.2.1) and encountered the original issue. Reopened.
PR: https://github.com/appcelerator/titanium_mobile_blackberry/pull/262
Tested and verified fixed with: Mac osx 10.9.3 Mavericks Appcelerator Studio, build: 3.3.0.201406061445 Titanium SDK, build: 3.3.0.v20140609184912 Node.JS Version: v0.10.13 NPM Version: 1.3.2 acs@1.0.14 alloy@1.4.0-beta npm@1.3.2 titanium@3.3.0-beta2 titanium-code-processor@1.1.1 Device: BB Z10 (10.2.1) Table view shows header text, subheader text and tablerow text.