{
"id": "153843",
"key": "TIMOB-20146",
"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": [],
"resolution": null,
"resolutiondate": null,
"created": "2015-12-15T03:48:37.000+0000",
"priority": {
"name": "High",
"id": "2"
},
"labels": [
"AL-5.4.0"
],
"versions": [],
"issuelinks": [],
"assignee": null,
"updated": "2018-02-28T19:55:59.000+0000",
"status": {
"description": "This issue was once resolved, but the resolution was deemed incorrect. From here issues are either marked assigned or resolved.",
"name": "Reopened",
"id": "4",
"statusCategory": {
"id": 2,
"key": "new",
"colorName": "blue-gray",
"name": "To Do"
}
},
"components": [
{
"id": "10206",
"name": "iOS",
"description": "iOS Platform"
}
],
"description": "h4. Steps to reproduce\r\n1. Create a new titanium classic app\r\n2. add true to tiapp.xml\r\n3. Change app.js to this:\r\n{code}\r\nvar mainWindow =Ti.UI.createWindow({\r\ntop:20,\r\nbackgroundColor:'white',\r\nlayout:'horizontal'\r\n});\r\n \r\nvar mainView = Ti.UI.createView({\r\nbackgroundColor:'white',\r\nlayout:'horizontal',\r\n});\r\n \r\n \r\nvar label1 = Ti.UI.createLabel({\r\ntext : 'label1 ',\r\n});\r\n \r\nvar label2 = Ti.UI.createLabel({\r\ntext : 'label2 ',\r\n});\r\nvar label3 = Ti.UI.createLabel({\r\ntext : 'label3 ',\r\n});\r\nvar label4 = Ti.UI.createLabel({\r\ntext : 'label4 ',\r\n});\r\n\r\nvar label5 = Ti.UI.createLabel({\r\ntext : 'label5 and more ',\r\nheight: 40\r\n});\r\n \r\nvar label6 = Ti.UI.createLabel({\r\ntext : 'label6 ',\r\nhorizontalWrap: true\r\n});\r\nvar label7 = Ti.UI.createLabel({\r\ntext : 'label7 ',\r\n});\r\nvar label8 = Ti.UI.createLabel({\r\ntext : 'label8 ',\r\n});\r\n \r\n// Add to the parent view.\r\nmainView.add(label1);\r\nmainView.add(label2);\r\nmainView.add(label3);\r\nmainView.add(label4);\r\nmainView.add(label5);\r\nmainView.add(label6);\r\nmainView.add(label7);\r\nmainView.add(label8);\r\n \r\nmainWindow.add(mainView);\r\nmainWindow.open();\r\n{code}\r\n\r\nh4. Expected result\r\nyou should see the labels 20pixels away from to top edge.\r\n\r\nh4. Actual result\r\nyou will see the labels right at the top edge.",
"attachment": [],
"flagged": false,
"summary": "iOS: Autolayout lays out wrongly when view is added to window",
"creator": {
"name": "cng",
"key": "cng",
"displayName": "Chee Kiat Ng",
"active": false,
"timeZone": "America/Los_Angeles"
},
"subtasks": [],
"reporter": {
"name": "cng",
"key": "cng",
"displayName": "Chee Kiat Ng",
"active": false,
"timeZone": "America/Los_Angeles"
},
"environment": "Ti SDK 5.2.0.v20151202153633\r\niOS 9.2",
"closedSprints": [
{
"id": 555,
"state": "closed",
"name": "2016 Sprint 1 SDK",
"startDate": "2016-01-02T01:31:50.127Z",
"endDate": "2016-01-16T01:31:00.000Z",
"completeDate": "2016-01-18T00:52:43.848Z",
"originBoardId": 114
}
],
"comment": {
"comments": [
{
"id": "391050",
"author": {
"name": "htbryant",
"key": "htbryant",
"displayName": "Harry Bryant",
"active": true,
"timeZone": "Europe/London"
},
"body": "Adding true to the tiapp.xml prevents the app from opening the window upon launch. This does not occur when autolayout is set to {{false}}.\r\n\r\n*Reopening Ticket.*\r\n\r\nTested On:\r\niPhone 6S (9.3.2) Device\r\nMac OSX El Capitan 10.11.5 \r\nTi SDK: 5.4.0.v20160713141635\r\nAppc Studio: 4.7.0.201607111053\r\nAppc NPM: 4.2.7\t\r\nApp CLI: 5.4.0-33\r\nXcode 7.3\r\nNode v4.4.7\r\n\r\n ",
"updateAuthor": {
"name": "htbryant",
"key": "htbryant",
"displayName": "Harry Bryant",
"active": true,
"timeZone": "Europe/London"
},
"created": "2016-07-19T22:42:40.000+0000",
"updated": "2016-07-19T22:42:40.000+0000"
}
],
"maxResults": 1,
"total": 1,
"startAt": 0
}
}
}