[TIMOB-16347] iOS: SectionHeader - Clicking on TableViewSection with custom properties throws a runtime error
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Open |
Resolution | Unresolved |
Affected Version/s | Release 3.2.0, Release 3.2.1 |
Fix Version/s | n/a |
Components | iOS |
Labels | qe-3.2.1, reprod |
Reporter | Wilson Luu |
Assignee | Unknown |
Created | 2014-01-30T21:24:17.000+0000 |
Updated | 2018-02-28T20:04:14.000+0000 |
Description
*Details:* Clicking on TableViewSection with custom properties throws a runtime error.
*This is not a regression since this occurs with 3.2.0.GA*
*Steps to reproduce:*
1. Install the following app.js to an iOS device:
var _window = Ti.UI.createWindow();
var tableData = [];
var s = 0;
var nRow = 0;
for (var i = 0; i < 100; i++) {
var createNewSection = (i + 1) % 10 == 9 || i == 0 ? true : false;
createNewSection ? nRow = 1 : nRow++;
tableData.push({
title : 'Row #' + nRow + ' Index #' + i + ' Section #' + s,
customProp : 'Hello World! #' + i,
header : createNewSection ? 'Section #' + s++ : null
});
}
var table = Ti.UI.createTableView({
data : tableData
});
_window.add(table);
table.addEventListener('longpress', function(e) {
Ti.API.info('Section: ' + e.section);
Ti.API.info('Row: ' + e.row);
Ti.API.info('Row Data: ' + e.rowData);
Ti.API.info('Index: ' + e.index);
Ti.API.info('customProp: ' + e.rowData.customProp);
});
_window.open();
2. After app is launched, long press on a section header
*Actual:* A runtime error is thrown (see attachments).
*Expected:* The following should be displayed in xcode console
[INFO] Section: [object TiUITableViewSection]
[INFO] Row: [object TiUITableViewRow]
[INFO] Row Data: [object TiUITableViewRow]
[INFO] Index: 4
[INFO] customProp: Hello World! #4
Attachments
File | Date | Size |
---|---|---|
runtime_error.txt | 2014-01-30T21:24:17.000+0000 | 368 |
Screenshot 2014.01.30 13.10.36.png | 2014-01-30T21:24:17.000+0000 | 109194 |
Issue still exists with SDK Version 3.2.1 and 3.4.0 Titanium Command-Line Interface, CLI version 3.3.0, Titanium SDK version 3.2.1.GA Titanium SDK version 3.4.0.GA Appcelerator Studio, build: 3.3.0.201407111535 iOS SDK: 7.0.3
I am able to reproduce this issue with the following environment; iPhone 7 (10.2) Studio 4.9.0.201705302345 Ti SDK 6.1.1.v20170620103414 Appc NPM 4.2.9 Appc CLI 6.2.1 Ti CLI 5.0.13 Alloy 1.9.11 Arrow 2.0.0 Xcode 8.2 (8C38) Node v4.8.2 Java 1.8.0_131