{ "id": "132120", "key": "AC-1425", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "3", "description": "The problem is a duplicate of an existing issue.", "name": "Duplicate" }, "resolutiondate": "2014-06-27T23:17:04.000+0000", "created": "2014-06-23T12:37:53.000+0000", "labels": [ "ios" ], "versions": [], "issuelinks": [], "assignee": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "updated": "2016-03-08T07:37:51.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": "14548", "name": "Titanium SDK & CLI", "description": "Please enter tickets related to the MobileSDK here." } ], "description": "Code snippet below shows the problem - {color:red}Unable to display popover; view is not attached to the current window{color}\r\n\r\n{code}\r\nvar win = Ti.UI.createWindow();\r\n\r\nvar table = Ti.UI.createTableView({\r\n\trowHeight : 40\r\n});\r\n\r\nvar row = Ti.UI.createTableViewRow({\r\n\r\n});\r\n\r\nvar tf = Ti.UI.createTextField({\r\n\thintText : \"Title\",\r\n\tleft : 5,\r\n\tright : 5,\r\n\teditable : false\r\n});\r\n\r\nrow.add(tf);\r\n\r\ntable.setData([row]);\r\n\r\ntable.addEventListener('click', function(e) {\r\n\r\n\tTi.API.info('You clicked row ' + e.index);\r\n\tTi.API.info('source ' + e.source);\r\n\r\n\tTi.API.info(JSON.stringify(e.row));\r\n\r\n\tvar popover = Ti.UI.iPad.createPopover({\r\n\t\twidth : 250,\r\n\t\theight : 100,\r\n\t\ttitle : 'a POpover',\r\n\r\n\t});\r\n\r\n\tpopover.contentView = Ti.UI.createTableView({\r\n\t\tdata : [{\r\n\t\t\ttitle : \"Mr.\"\r\n\t\t}, {\r\n\t\t\ttitle : \"Dr.\"\r\n\t\t}, {\r\n\t\t\ttitle : \"Ms.\"\r\n\t\t}, {\r\n\t\t\ttitle : \"Mrs.\"\r\n\t\t}],\r\n\t\trowHeight : 40\r\n\t});\r\n\t//popover.show({view:e.source});\r\n\tpopover.show();\r\n\r\n});\r\n\r\nwin.add(table);\r\n\r\nwin.open();\r\n{code}", "attachment": [], "flagged": false, "summary": "iOS : iPad cannot show a popover with tableView as its contentView", "creator": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Ti SDK 3.2.3\r\niOS 7.1", "comment": { "comments": [ { "id": "311467", "author": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "updateAuthor": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "created": "2014-06-27T23:17:04.000+0000", "updated": "2014-06-27T23:17:04.000+0000" }, { "id": "311498", "author": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Why is this ticket closed??? IT IS NOT RESOLVED IN SDK 3.2.3. Did you not see my environment???? ", "updateAuthor": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-06-28T23:38:41.000+0000", "updated": "2014-06-28T23:38:41.000+0000" }, { "id": "311499", "author": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Also, this ticket is different the one you mentioned, my one is trying to set the tableview to the contentView attribute\r\n", "updateAuthor": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-06-28T23:40:29.000+0000", "updated": "2014-06-28T23:40:29.000+0000" }, { "id": "311503", "author": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "body": "Hello [~jialhe85@gmail.com], \r\nI did some testing like this:\r\n\r\n{code}\r\nvar win = Ti.UI.createWindow();\r\n\r\nvar button = Ti.UI.createButton({title: 'Open Popover!'});\r\nbutton.addEventListener('click', function(e){\r\n popover.show({ view: button });\r\n});\r\nwin.add(button);\r\n\r\nvar view = Ti.UI.createView({backgroundColor: 'green'});\r\nvar tableData = [ {title: 'Apples'}, {title: 'Bananas'}, {title: 'Carrots'}, {title: 'Potatoes'} ];\r\n\r\nvar table = Ti.UI.createTableView({\r\n data: tableData\r\n});\r\n\r\nview.add(table);\r\n\r\nvar popover = Ti.UI.iPad.createPopover({\r\n width: 250,\r\n height: 100,\r\n title: 'Kermit',\r\n //rightNavButton: rightButton\r\n});\r\npopover.add(view);\r\n\r\nwin.open();\r\n{code}\r\n\r\nand works just fine with 3.3.0.Beta.\r\n\r\nBest,\r\nMauro ", "updateAuthor": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "created": "2014-06-29T01:57:21.000+0000", "updated": "2014-06-29T01:57:21.000+0000" }, { "id": "311505", "author": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Thanks Mauro\r\n\r\nI will re-test it using 3.3.0 beta", "updateAuthor": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-06-29T02:04:22.000+0000", "updated": "2014-06-29T02:04:22.000+0000" } ], "maxResults": 6, "total": 6, "startAt": 0 } } }