{ "id": "78262", "key": "TIMOB-4800", "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": "13271", "description": "Release 2.1.0", "name": "Release 2.1.0", "archived": false, "released": true, "releaseDate": "2012-06-29" }, { "id": "13207", "name": "Sprint 2012-07", "archived": true, "released": true, "releaseDate": "2012-04-08" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2012-07-12T04:16:47.000+0000", "created": "2011-07-26T17:26:38.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "api", "module_view", "qe-testadded" ], "versions": [ { "id": "11244", "name": "Release 1.7.0", "archived": true, "released": true, "releaseDate": "2011-06-13" }, { "id": "11367", "description": "", "name": "Release 1.7.1", "archived": true, "released": true, "releaseDate": "2011-06-21" }, { "id": "11570", "description": "", "name": "Release 1.7.2", "archived": true, "released": true, "releaseDate": "2011-07-21" }, { "id": "11331", "description": "", "name": "Release 1.8.0", "archived": true, "released": true, "releaseDate": "2011-10-31" } ], "issuelinks": [ { "id": "20693", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "100701", "key": "TIMOB-10824", "fields": { "summary": "Android: backgroundColor/backgroundImage/backgroundRepeat compositing not working with heavyweight windows", "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" } }, "priority": { "name": "Medium", "id": "3" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2012-09-10T12:26:45.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": "h3. Setting background on Root Window\r\n\r\n1) Create project in TiStudio and replace app.js with \r\n\r\n{code:JavaScript}\r\nTi.UI.backgroundColor = '#f00';\r\nTi.UI.backgroundImage = 'KS_nav_ui.png';\r\n\r\nvar win = Ti.UI.createWindow();\r\nwin.open();\r\n{code}\r\n\r\n(or use attached Resources folder)\r\n\r\n2) Launch application\r\n\r\nExpected: Image appears with a red background.\r\nActual: Only image appears. (See screen shot)\r\n\r\nNote: \r\nTalked to Jon Alter about this. He says it isn't a major issue because he doesn't see a circumstance where someone would set the background this way.\r\n\r\nIt is a parity issue. Setting the background this way works as expected on iOS devices.\r\n\r\nh3. Setting background on a view.\r\n\r\nVerify image is shown with a red background.\r\nAlso verify background color changes when the state of the\r\nview changes (ex: focused, selected).\r\n\r\n{code:JavaScript}\r\nvar win = Ti.UI.createWindow({\r\n\tbackgroundColor: 'white',\r\n\tlayout: 'vertical'\r\n});\r\n\r\nvar colorView = Ti.UI.createView({\r\n\twidth: 400, height: 400,\r\n\tfocusable: true,\r\n\tbackgroundColor: 'blue',\r\n\tbackgroundImage: 'background.png',\r\n\tbackgroundSelectedColor: 'red',\r\n\tbackgroundFocusedColor: 'yellow',\r\n\tbackgroundDisabledColor: 'black'\r\n});\r\nwin.add(colorView);\r\n\r\nvar disableButton = Ti.UI.createButton({\r\n\ttitle: 'Enable/Disable View',\r\n\twidth: 150\r\n});\r\ndisableButton.on('click', function() {\r\n\tcolorView.enabled = !colorView.enabled;\r\n});\r\nwin.add(disableButton);\r\n\r\nwin.open();\r\n{code}\r\n", "attachment": [ { "id": "21975", "filename": "device.png", "author": { "name": "avaghti", "key": "avaghti", "displayName": "Alan Vaghti", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-07-26T17:26:38.000+0000", "size": 59543, "mimeType": "image/png" }, { "id": "21974", "filename": "Resources.zip", "author": { "name": "avaghti", "key": "avaghti", "displayName": "Alan Vaghti", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-07-26T17:26:38.000+0000", "size": 2310699, "mimeType": "application/zip" }, { "id": "26228", "filename": "Screen Shot 2012-03-14 at 10.00.54 PM.png", "author": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "created": "2012-03-14T21:06:41.000+0000", "size": 156927, "mimeType": "image/png" } ], "flagged": false, "summary": "Ti.UI.backgroundColor/Ti.UI.backgroundImage not translucent", "creator": { "name": "avaghti", "key": "avaghti", "displayName": "Alan Vaghti", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "avaghti", "key": "avaghti", "displayName": "Alan Vaghti", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "SDK 1.7.0, 1.7.1, 1.7.2, 1.8.0v20110725142947. HTC Hero running 2.1-update1, Nexus One running 2.2.2, Xoom tablet running 3.2. Titanium Studio, build: 1.0.2.201107130739.", "comment": { "comments": [ { "id": "186562", "author": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "body": "This bug applies to views of all sorts, in addition to windows as described here. See the screen shot I attached (side-by-side simulators). I'm using a transparent gradient png in addition to a background color to provide visual depth to the columns in the chart. On iOS, they are translucent and show the background color. On Android, the background color is masked.\r\n\r\n{code}\r\nvar bar = Ti.UI.createView({\r\n width:'100%',\r\n height: 100,\r\n backgroundColor: 'blue',\r\n backgroundImage: 'gradient1.png',\r\n left: 0, right: 0,\r\n bottom:32\t\t\r\n});\r\n{code}\r\n\r\nTested on various SDKs including 2.0.0.v20120314154741", "updateAuthor": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "created": "2012-03-14T21:06:41.000+0000", "updated": "2012-03-14T21:06:41.000+0000" }, { "id": "186613", "author": { "name": "ngupta", "key": "ngupta", "displayName": "Neeraj Gupta", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Documentation team needs this fix for samples.", "updateAuthor": { "name": "ngupta", "key": "ngupta", "displayName": "Neeraj Gupta", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-03-15T09:43:35.000+0000", "updated": "2012-03-15T09:43:35.000+0000" }, { "id": "189771", "author": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Pull request [#1916|https://github.com/appcelerator/titanium_mobile/pull/1916] sent.", "updateAuthor": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-04-04T00:40:52.000+0000", "updated": "2012-04-04T00:40:52.000+0000" }, { "id": "195979", "author": { "name": "aevans", "key": "aevans", "displayName": "Arthur Evans", "active": true, "timeZone": "America/Los_Angeles" }, "body": "It appears that normal background images (i.e., View.backgroundImage) are now translucent. That is, if you set both View.backgroundColor and View.backgroundImage, they are composited now.\r\n\r\nIn 2.0.1 and earlier, the image is not composited with the BG color unless:\r\n\r\n- Window.windowPixelFormat is translucent, for example, Ti.UI.Android.PIXEL_FORMAT_TRANSLUCENT.\r\n- Window.modal is true (modal windows are always translucent)\r\n\r\nIs this related? Is it a regression?", "updateAuthor": { "name": "aevans", "key": "aevans", "displayName": "Arthur Evans", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-05-24T13:06:05.000+0000", "updated": "2012-05-24T13:06:05.000+0000" }, { "id": "198979", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified fixed with SDK 2.1.0.v20120618102300 on Droid", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-06-18T14:55:40.000+0000", "updated": "2012-06-18T14:55:40.000+0000" }, { "id": "202893", "author": { "name": "nchhabra", "key": "nchhabra", "displayName": "Neha Chhabra", "active": true, "timeZone": "Asia/Kolkata" }, "body": "Reopening to update labels.", "updateAuthor": { "name": "nchhabra", "key": "nchhabra", "displayName": "Neha Chhabra", "active": true, "timeZone": "Asia/Kolkata" }, "created": "2012-07-12T04:16:12.000+0000", "updated": "2012-07-12T04:16:12.000+0000" } ], "maxResults": 7, "total": 7, "startAt": 0 } } }