{ "id": "61701", "key": "TIMOB-1069", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "11224", "name": "Release 1.4.0", "archived": true, "released": true, "releaseDate": "2010-07-16" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2011-04-17T01:55:07.000+0000", "created": "2011-04-15T02:43:07.000+0000", "priority": { "name": "Trivial", "id": "5" }, "labels": [ "ios", "iphone", "mobilesdk", "scrollview", "tableview", "tableviewrow" ], "versions": [], "issuelinks": [], "assignee": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2011-04-17T01:55:07.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "{html}

http://helpdesk.appcelerator.net/tickets/2844

\n

test case attached to ticket. each row has a unique class name\nbut for some reason our code complains that it doesn't

{html}", "attachment": [ { "id": "17924", "filename": "app.js", "author": { "name": "alanmcconnell", "key": "alanmcconnell", "displayName": "Alan McConnell", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:43:07.000+0000", "size": 2222, "mimeType": "application/x-javascript" }, { "id": "17923", "filename": "default_app_logo.png", "author": { "name": "alanmcconnell", "key": "alanmcconnell", "displayName": "Alan McConnell", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:43:07.000+0000", "size": 87937, "mimeType": "image/png" } ], "flagged": false, "summary": "table view rows with scroll view crashes when simply scrolling the table view", "creator": { "name": "nwright", "key": "nwright", "displayName": "Nolan Wright", "active": false, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "nwright", "key": "nwright", "displayName": "Nolan Wright", "active": false, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "124754", "author": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Mail that was sent to the customer:

\n

It appears that, for some reason, UITableView (The underlying\niPhone class) treats the strings in the ClassName as identical. I'm\nnot sure why this is, (It might be that it stops looking at the\nstring after a set number of characters) and I'll look into it, but\nin the mean time, here's a workaround:

\n

Remove the custom className from the tableRow's creation. When\nthe className property is missing, Titanium actually generates a\nclassname of its own internally (Using the memory pointer as the\nunique key -- which is faster than UUIDs as a bonus), and the\nwarnings and crashes went away.

{html}", "updateAuthor": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:43:07.000+0000", "updated": "2011-04-15T02:43:07.000+0000" }, { "id": "124755", "author": { "name": "alanmcconnell", "key": "alanmcconnell", "displayName": "Alan McConnell", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Hey Blain,
\nThanks for getting back to me. I tried the workaround (eliminating\nthe className property altogether) and I still get the \"different\nlayout than expected error\" and a crash if I scroll all the way to\nthe bottom and all the way back to the top in the app.js I attached\nto my ticket (I've attached it here as well). I also tried manually\nspecifying a short, unique className and still got this behavior in\nthe attach app.js.

\n

It's strange, I believe I've only seen this behavior when a\nScrollView is present in a table row, but with it in there\nclassName seems to be totally ignored.

\n

2010-06-02 20:38:42.504 TableViewTest[603:207]\nTerminating app due to uncaught exception\n'NSInvalidArgumentException', reason: '\n-[UIScrollView transferProxy:]: unrecognized selector sent to\ninstance 0x5333fd0'

{html}", "updateAuthor": { "name": "alanmcconnell", "key": "alanmcconnell", "displayName": "Alan McConnell", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:43:08.000+0000", "updated": "2011-04-15T02:43:08.000+0000" }, { "id": "124756", "author": { "name": "alanmcconnell", "key": "alanmcconnell", "displayName": "Alan McConnell", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Meant to attach the app.js file.

{html}", "updateAuthor": { "name": "alanmcconnell", "key": "alanmcconnell", "displayName": "Alan McConnell", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:43:08.000+0000", "updated": "2011-04-15T02:43:08.000+0000" }, { "id": "124757", "author": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Okay, I did a regression test. App.js crashes in 1.3, and does\nfine in HEAD. The difference being the fix/test for un-named\nclasses happened some time since then. (I need to write these\nthings down)

\n

A few solutions: 1) Either pull from HEAD and build a fresh\npost-1.3 build of Titanium, or 2) have Nolan provide you with\nsame.

\n

Another workaround would be that the identifier doesn't need to\nbe wholly unique, just unique within that table view. So if you\nwere to simply have the row number (With no preceeding common text)\nas the className, or a counter if you intend to modify rows later\non, that should be sufficient for unique rows.

{html}", "updateAuthor": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:43:09.000+0000", "updated": "2011-04-15T02:43:09.000+0000" }, { "id": "124758", "author": { "name": "jhaynie", "key": "jhaynie", "displayName": "Jeff Haynie", "active": false, "timeZone": "America/Los_Angeles" }, "body": "{html}

(from [97825f3c1179e136a01e83741bbc0614f3b372fd])\nCloses #1069 , with debugging cleaned up: TableViewRows\nwere looking at the TiUIView's subviews, instead of the views of\ntheir proxy's children. Most times, this is okay. But things get\nvery confused very quickly with scrollable/scrolling views.\n\nhttp://github.com/appcelerator/titanium_mobile/commit/97825f3c1179e...

{html}", "updateAuthor": { "name": "jhaynie", "key": "jhaynie", "displayName": "Jeff Haynie", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:43:09.000+0000", "updated": "2011-04-15T02:43:09.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }