{ "id": "90641", "key": "TIMOB-8942", "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": "14164", "description": "Release 3.0.2", "name": "Release 3.0.2", "archived": true, "released": true, "releaseDate": "2013-02-19" } ], "resolution": { "id": "5", "description": "All attempts at reproducing this issue failed, or not enough information was available to reproduce the issue. Reading the code produces no clues as to why this behavior would occur. If more information appears later, please reopen the issue.", "name": "Cannot Reproduce" }, "resolutiondate": "2013-03-19T08:26:04.000+0000", "created": "2012-04-20T11:16:29.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "2.0.1", "TableView", "core", "parity", "tableviewrows" ], "versions": [ { "id": "13272", "description": "Release 2.0.1", "name": "Release 2.0.1", "archived": true, "released": true, "releaseDate": "2012-04-16" } ], "issuelinks": [], "assignee": { "name": "jithinv@exalture.com", "key": "jithinv@exalture.com", "displayName": "jithinpv", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-03-21T21:25:09.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": "10202", "name": "Android", "description": "Android Platform" } ], "description": "h6.Issue\r\nIf We create a tableView that has a minRowHeight using the new height/width values, The minRowheight appears to be used as the actual height of the row.\r\nThe failure occurs when assigning the height: Ti.UI.SIZE value to the tableViewRow. \r\n\r\nh6.Tested on\r\nAndroid Emulator 2.2\r\nDroid Razr 2.3.5\r\n\r\nh6.Expected behavior\r\nThe row is composed of a label with height:Ti.UI.SIZE. If the row is not composed of any object it seems to work ok. \r\n\r\nh6.Current behavior\r\nIn the failure case: a minRowHeight seems to be used as the actual height of the row. If there is no minRowHeight assigned it appears to use 0 as the height of the row.\r\n \r\nh6.Repro sequence\r\n{code}\r\n// this sets the background color of the master UIView (when there are no windows/tab groups on it)\r\nTitanium.UI.setBackgroundColor('#000');\r\n\r\n// create tab group\r\nvar tabGroup = Titanium.UI.createTabGroup();\r\n\r\n\r\n//\r\n// create base UI tab and root window\r\n//\r\nvar win1 = Titanium.UI.createWindow({ \r\n title:'Tab 1',\r\n backgroundColor:'#fff',\r\n layout:'vertical'\r\n});\r\nvar tab1 = Titanium.UI.createTab({ \r\n icon:'KS_nav_views.png',\r\n title:'Tab 1',\r\n window:win1\r\n});\r\n\r\nvar label1 = Titanium.UI.createLabel({\r\n\tcolor:'#999',\r\n\ttext:'I am Window 1',\r\n\tfont:{fontSize:20,fontFamily:'Helvetica Neue'},\r\n\ttextAlign:'center',\r\n\twidth:'auto'\r\n});\r\n\r\nwin1.add(label1);\r\n\r\n//\r\n// create controls tab and root window\r\n//\r\nvar win2 = Titanium.UI.createWindow({ \r\n title:'Tab 2',\r\n backgroundColor:'#fff'\r\n});\r\nvar tab2 = Titanium.UI.createTab({ \r\n icon:'KS_nav_ui.png',\r\n title:'Tab 2',\r\n window:win2\r\n});\r\n\r\nvar label2 = Titanium.UI.createLabel({\r\n\tcolor:'#999',\r\n\ttext:'I am Window 2',\r\n\tfont:{fontSize:20,fontFamily:'Helvetica Neue'},\r\n\ttextAlign:'center',\r\n\twidth:'auto'\r\n});\r\n\r\nwin2.add(label2);\r\n\r\n\r\n\r\n//\r\n// add tabs\r\n//\r\ntabGroup.addTab(tab1); \r\ntabGroup.addTab(tab2); \r\n\r\n\r\n// open tab group\r\ntabGroup.open();\r\n\r\nvar aTableView1 = Ti.UI.createTableView ({\r\n\theight: Ti.UI.SIZE,\r\n\twidth: Ti.UI.FILL,\r\n\tminRowHeight: 10,\r\n\tbackgroundColor:'red',\r\n});\r\n\r\nvar aTableView2 = Ti.UI.createTableView ({\r\n\theight: Ti.UI.SIZE,\r\n\twidth: Ti.UI.FILL,\r\n\tbackgroundColor:'yellow',\r\n});\r\n\r\nTi.include('helpers.js');\r\nwin1.add(Ti.UI.createLabel({text:'This tableView has a minRowHeight set to 10, the Rows have no height or width property and is composed of label with height=Ti.UI.SIZE'}));\r\nwin1.add(aTableView1);\r\naddDataRow('row1 minRowHeight',aTableView1);\r\naddDataRow('row2 minRowHeight',aTableView1);\r\n\r\nwin1.add(Ti.UI.createLabel({text:'This tableView has no minRowHeight, the Rows have no height or width property and is composed of label with height=Ti.UI.SIZE'}));\r\nwin1.add(aTableView2);\r\naddDataRow('row1',aTableView2);\r\naddDataRow('row2',aTableView2);\r\n\r\n\r\nvar aTableView11 = Ti.UI.createTableView ({\r\n\theight: Ti.UI.SIZE,\r\n\twidth: Ti.UI.FILL,\r\n\tminRowHeight: 10,\r\n\tbackgroundColor:'red',\r\n});\r\n\r\nvar aTableView21 = Ti.UI.createTableView ({\r\n\theight: Ti.UI.SIZE,\r\n\twidth: Ti.UI.FILL,\r\n\tbackgroundColor:'blue',\r\n});\r\n\r\nwin1.add(Ti.UI.createLabel({text:'This tableView has a minRowHeight set to 10, the Rows have height:Ti.UI.SIZE, width:Ti.UI.FILL and is composed of label with height=Ti.UI.SIZE'}));\r\nwin1.add(aTableView11);\r\naddDataRowBad('row1 minRowHeight',aTableView11);\r\naddDataRowBad('row2 minRowHeight',aTableView11);\r\n\r\nwin1.add(Ti.UI.createLabel({text:'This tableView has a no minRowHeight, the Rows have height:Ti.UI.SIZE, width:Ti.UI.FILL and is composed of label with height=Ti.UI.SIZE'}));\r\nwin1.add(aTableView21);\r\naddDataRowBad('row1',aTableView21);\r\naddDataRowBad('row2',aTableView21);\r\n{code}\r\n\r\n\r\nh6.helpers.js\r\n{code}\r\naddDataRow = function(theText, theTable) {\r\n\tvar row = Ti.UI.createTableViewRow({\r\n\t\tlayout:'vertical'\r\n\t});\r\n\tvar nameLabel = Ti.UI.createLabel({\r\n\t\ttext : theText,\r\n\t\tcolor : 'black',\r\n\t\theight:Ti.UI.SIZE,\r\n\t});\r\n\trow.add(nameLabel);\r\n\ttheTable.appendRow(row);\r\n}\r\n\r\naddDataRowBad = function(theText, theTable) {\r\n\tvar row = Ti.UI.createTableViewRow({\r\n\t\theight:Ti.UI.SIZE,\r\n\t\twidth:Ti.UI.FILL,\r\n\t});\r\n\tvar nameLabel = Ti.UI.createLabel({\r\n\t\theight:Ti.UI.SIZE,\r\n\t\ttext : theText,\r\n\t\tcolor : 'black',\r\n\t});\r\n\trow.add(nameLabel);\r\n\t//row.add(nameLabel1);\r\n\ttheTable.appendRow(row);\r\n}\r\n{code}\r\nhttp://docs.appcelerator.com/titanium/2.0/index.html#!/api/Titanium.UI.TableView-property-minRowHeight", "attachment": [ { "id": "27474", "filename": "AndroidOS_2.2.jpg", "author": { "name": "egomez", "key": "egomez", "displayName": "Eduardo Gomez", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2012-05-01T00:46:47.000+0000", "size": 77953, "mimeType": "image/jpeg" }, { "id": "36436", "filename": "Screenshot_2013-03-19-13-29-54.png", "author": { "name": "jithinv@exalture.com", "key": "jithinv@exalture.com", "displayName": "jithinpv", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-19T08:32:48.000+0000", "size": 52633, "mimeType": "image/png" }, { "id": "36437", "filename": "Screen Shot 2013-03-19 at 1.52.16 PM.png.jpg", "author": { "name": "jithinv@exalture.com", "key": "jithinv@exalture.com", "displayName": "jithinpv", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-19T08:37:23.000+0000", "size": 151228, "mimeType": "image/jpeg" }, { "id": "27317", "filename": "TableViewRowBug.zip", "author": { "name": "miltgrin", "key": "miltgrin", "displayName": "Milt Grinberg", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-04-20T11:16:29.000+0000", "size": 750293, "mimeType": "application/zip" } ], "flagged": false, "summary": "Android: TableView using minRowHeight fails when tableViewRow has a composite object", "creator": { "name": "miltgrin", "key": "miltgrin", "displayName": "Milt Grinberg", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "miltgrin", "key": "miltgrin", "displayName": "Milt Grinberg", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Android 2.2 & 2.3\r\nTitanium SDK 2.0.1.GA2", "comment": { "comments": [ { "id": "192048", "author": { "name": "miltgrin", "key": "miltgrin", "displayName": "Milt Grinberg", "active": true, "timeZone": "America/Los_Angeles" }, "body": "In the actual code I had a copy/paste error in the first two labels on the screen. They are not composed of a label and just put the text value on the row. ", "updateAuthor": { "name": "miltgrin", "key": "miltgrin", "displayName": "Milt Grinberg", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-04-20T11:23:32.000+0000", "updated": "2012-04-20T11:23:32.000+0000" }, { "id": "242868", "author": { "name": "jithinv@exalture.com", "key": "jithinv@exalture.com", "displayName": "jithinpv", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Issue does not reproduces \r\n\r\nTested with\r\n\r\nTitanium Studio, build: 3.0.1.201212181159\r\nTitanium SDK version: 3.1.0 (03/11/13 15:43 0c88429)\r\nTitanium SDK version: 3.0.2 (02/07/13 16:46 a4def81)\r\nDevice: Samsung galaxy s duos Android version: 4.0.4 WVGA DISPLAY\r\nAndroid Emulator: Android SDK version: 2.2 HVGA DISPLAY \r\n\r\njithinpv\r\n", "updateAuthor": { "name": "jithinv@exalture.com", "key": "jithinv@exalture.com", "displayName": "jithinpv", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-19T08:26:04.000+0000", "updated": "2013-03-19T08:26:04.000+0000" }, { "id": "414439", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as the issue cannot be reproduced.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-03-21T21:25:09.000+0000", "updated": "2017-03-21T21:25:09.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }