{ "id": "121269", "key": "TIMOB-15501", "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": "15922", "description": "2014 Sprint 03", "name": "2014 Sprint 03", "archived": true, "released": true, "releaseDate": "2014-02-14" }, { "id": "15923", "description": "2014 Sprint 03 API", "name": "2014 Sprint 03 API", "archived": true, "released": true, "releaseDate": "2014-02-14" } ], "resolution": { "id": "2", "description": "The problem described is an issue which will never be fixed.", "name": "Won't Fix" }, "resolutiondate": "2014-02-03T23:55:47.000+0000", "created": "2013-10-16T09:55:17.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "supportTeam", "triage" ], "versions": [ { "id": "15479", "description": "Release 3.1.2", "name": "Release 3.1.2", "archived": true, "released": true, "releaseDate": "2013-07-31" }, { "id": "15593", "description": "Release 3.1.3", "name": "Release 3.1.3", "archived": true, "released": true, "releaseDate": "2013-09-18" } ], "issuelinks": [], "assignee": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2017-03-22T18:27:02.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": "When using multiple views with scrollable view, flickering effect if observed in iOS7 with 3.1.3.GA.\r\n\r\nSteps to reproduce:\r\n\r\n1: Use the sample code1 to reproduce the issue.\r\n2: Use the code in app.js of a newly created project.\r\n3: Build the project for iOS7 device (Simulator does not reproduce it).\r\n4: check the effect while changing the orientation.\r\n\r\nNote: sample code 2, does not reproduce the issue. Having less views in container view.\r\n**Sample code1 - can reproduce issue**\r\n\r\n{code}\r\nvar headerView = Ti.UI.createView({\r\n\r\n\tbackgroundColor : '#DB2027',\r\n\theight : '40dp'\r\n});\r\n\r\nvar headerTitle = Ti.UI.createLabel({\r\n\r\n\ttext : \"Main Window\",\r\n\tfont : {\r\n\t\tfontSize : '20dp',\r\n\t\tfontWeight : 'bold'\r\n\t},\r\n\ttextAlign : Ti.UI.TEXT_ALIGNMENT_CENTER,\r\n\tcolor : '#FFFFFF'\r\n\r\n});\r\n\r\nheaderView.add(headerTitle);\r\n\r\n// btn\r\n\r\nvar leftBtnSetting = Ti.UI.createButton({\r\n\tsettingsOpen : false,\r\n\tleft : '5dp',\r\n\theight : '15dp',\r\n\tstyle : Ti.UI.iPhone.SystemButtonStyle.PLAIN,\r\n\ttitle : \"Ashish\"\r\n});\r\n\r\nheaderView.add(leftBtnSetting);\r\n\r\nvar rtBtn = Ti.UI.createButton({\r\n\ttitle : \"right\",\r\n\t//color: 'white',\r\n\tfont : {\r\n\t\tfontSize : '15dp',\r\n\t},\r\n\tright : '5dp'\r\n});\r\n\r\nheaderView.add(rtBtn);\r\n\r\n// btn end\r\n\r\nvar win = Ti.UI.createWindow({\r\n\ttop : 20,\r\n\tbackgroundColor : \"black\",\r\n\torientationModes : [Ti.UI.PORTRAIT, Ti.UI.LANDSCAPE_LEFT, Ti.UI.LANDSCAPE_RIGHT]\r\n});\r\n\r\nvar containerView = Ti.UI.createView({\r\n\tbackgroundColor : \"gray\",\r\n\ttop : 0,\r\n\tlayout : \"vertical\"\r\n});\r\n\r\ncontainerView.add(headerView);\r\n\r\n//view 1\r\n\r\nvar surveyView = Ti.UI.createView({\r\n\tbackgroundColor : '#d0d0d0',\r\n\tlayout : 'vertical'\r\n});\r\n\r\nvar surveyNames = ['Check1', 'Check2', 'Check3', 'Check4', 'Check5'];\r\nvar surveyUnits = ['(feet)', '(degrees)', '(degrees)', '(feet)', '(deg/100 ft)'];\r\n\r\nfunction createColumnHeader (names, units){\r\n \r\n \r\n var viewWidth = (100/names.length).toString() + '%';\r\n \r\n var headerView = Ti.UI.createView({\r\n height : '60dp',\r\n layout : 'horizontal',\r\n backgroundColor : '#CCCCCC'\r\n });\r\n \r\n \r\n names.forEach(function(e, i){\r\n \r\n var view = Ti.UI.createView({\r\n width : viewWidth,\r\n height : headerView.height,\r\n left : '0dp',\r\n borderWidth : 0.3,\r\n borderColor : '#444444',\r\n layout: 'vertical'\r\n });\r\n \r\n var label = Ti.UI.createLabel({\r\n text : e,\r\n top : '10dp',\r\n color : '#333333',\r\n textAlign : Ti.UI.TEXT_ALIGNMENT_CENTER,\r\n font : {\r\n fontSize : '12dp',\r\n fontWeight : 'bold'\r\n }\r\n \r\n });\r\n \r\n label.setHeight(Ti.UI.SIZE);\r\n \r\n view.add(label);\r\n \r\n if(units)\r\n {\r\n var unitLabel = Ti.UI.createLabel({\r\n text : units[i],\r\n textAlign : Ti.UI.TEXT_ALIGNMENT_CENTER,\r\n font : {\r\n fontSize : '10dp'\r\n }\r\n \r\n });\r\n view.add(unitLabel);\r\n }\r\n \r\n //view.setHeight(Ti.UI.SIZE);\r\n \r\n headerView.add(view);\r\n });\r\n \r\n //headerView.setHeight(Ti.UI.SIZE);\r\n return headerView;\r\n \r\n};\r\n\r\nvar surveyHeaderView = createColumnHeader(surveyNames, surveyUnits);\r\n\r\nsurveyView.add(surveyHeaderView);\r\n\r\nvar rows = [];\r\n\r\nvar values = [3000, 4000, 5000, 6000, 7000];\r\n\r\nfunction createSurveyPageRow (values){\r\n \r\n \r\n var viewWidth = (100/values.length).toString() + '%';\r\n \r\n var tableRow = Ti.UI.createTableViewRow({\r\n height : '40dp',\r\n className : 'surveyRow',\r\n backgroundColor : '#EEEEEE'\r\n });\r\n \r\n var rowView = Ti.UI.createView({\r\n height : '40dp',\r\n layout : 'horizontal'\r\n });\r\n \r\n \r\n values.forEach(function(e){\r\n \r\n var view = Ti.UI.createView({\r\n width : viewWidth,\r\n height : rowView.height,\r\n left : '0dp',\r\n layout: 'vertical'\r\n });\r\n \r\n var label = Ti.UI.createLabel({\r\n text : e,\r\n top : '10dp',\r\n textAlign : Ti.UI.TEXT_ALIGNMENT_CENTER,\r\n font : {\r\n fontSize : '12dp'\r\n }\r\n \r\n });\r\n \r\n view.add(label);\r\n \r\n rowView.add(view);\r\n });\r\n \r\n tableRow.add(rowView);\r\n return tableRow;\r\n \r\n};\r\n\r\nfor ( i = 0; i < 5; i++) {\r\n\trows.push(createSurveyPageRow(values));\r\n}\r\n\r\nvar tableView = Ti.UI.createTableView({\r\n\tdata : rows,\r\n});\r\n\r\nsurveyView.add(tableView);\r\n\r\n//view end\r\n\r\n// var view1 = Ti.UI.createView({\r\n\t// width : Ti.UI.FILL,\r\n\t// height : Ti.UI.FILL,\r\n\t// backgroundColor : \"red\"\r\n// });\r\n\r\n// var view2 = Ti.UI.createView({\r\n\t// width : Ti.UI.FILL,\r\n\t// height : Ti.UI.FILL,\r\n\t// backgroundColor : \"yellow\"\r\n// });\r\n\r\ncreateLithologyPageRow = function(data){\r\n \r\n //var key = Object.keys(data);\r\n \r\n //alert(key.length);\r\n \r\n var keys = Object.keys(data); // Get an array of property names for object o\r\n var values = []; // Store matching property values in this array \r\n for(var i = 0; i < keys.length; i++) { // For each index in the array\r\n var key = keys[i]; // Get the key at that index\r\n values[i] = data[key]; // Store the value in the values array \r\n }\r\n \r\n var viewWidth = (100/keys.length).toString() + '%';\r\n \r\n \r\n var tableRow = Ti.UI.createTableViewRow({\r\n backgroundColor : '#666666',\r\n className : 'lithologyRow'\r\n });\r\n \r\n var rowView = Ti.UI.createView({\r\n top : '0dp',\r\n bottom : '0dp',\r\n layout : 'horizontal'\r\n });\r\n \r\n \r\n //keys.forEach(function(e, index){\r\n for(index=0; index