{ "id": "63295", "key": "TIMOB-2663", "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": { "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": "2014-02-21T15:15:42.000+0000", "created": "2011-04-15T03:26:21.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "core" ], "versions": [ { "id": "13505", "description": "Release 3.0.0", "name": "Release 3.0.0", "archived": true, "released": true, "releaseDate": "2012-12-14" } ], "issuelinks": [], "assignee": { "name": "sunila", "key": "sunila", "displayName": "Sunila", "active": true, "timeZone": "Asia/Kolkata" }, "updated": "2017-03-27T20:12: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": "10202", "name": "Android", "description": "Android Platform" } ], "description": "{html}

Problem#1:

\r\n

When initializing an object (such as a view) and setting its'\r\nopacity to 0 initially (e.g. opacity: 0), then changing it using\r\nobj.animate(opacity: 0.6, duration: 1) yields no result. For\r\nexample:

\r\n
\r\nvar viewObj = Ti.UI.createView({\r\n    // other properties\r\n    opacity: 0\r\n});\r\n\r\n// inside some handler; onClick if we try changing opacity\r\nviewObj.animate({\r\n    opacity: 0.6,\r\n    duration: 1\r\n});\r\n\r\n// yeilds no result\r\n
\r\n

Problem#2:

\r\n

Changing the opacity with direct assignment or using the\r\n\"setOpacity\" method doesn't update the object with the new opacity,\r\nbut outputting it on to the console shows the opacity property has\r\nbeen changed however.

\r\n

For more information kindly refer to this thread; \r\nhttp://developer.appcelerator.com/question/92891/android-setopacity...

{html}", "attachment": [], "flagged": false, "summary": "Android: Opacity problem", "creator": { "name": "daniyal", "key": "daniyal", "displayName": "daniyal", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "daniyal", "key": "daniyal", "displayName": "daniyal", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "129132", "author": { "name": "daniyal", "key": "daniyal", "displayName": "daniyal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

I forgot to mentioned; I'm using Titanium SDK 1.5.0 and Android\nSDK 2.2

{html}", "updateAuthor": { "name": "daniyal", "key": "daniyal", "displayName": "daniyal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:26:21.000+0000", "updated": "2011-04-15T03:26:21.000+0000" }, { "id": "129133", "author": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Assigning to Don for triage.

{html}", "updateAuthor": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:26:21.000+0000", "updated": "2011-04-15T03:26:21.000+0000" }, { "id": "175955", "author": { "name": "taazzago", "key": "taazzago", "displayName": "Taazza GO", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Any updates on this issue? Still reproducible.", "updateAuthor": { "name": "taazzago", "key": "taazzago", "displayName": "Taazza GO", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-12-13T10:48:15.000+0000", "updated": "2011-12-13T10:48:15.000+0000" }, { "id": "184474", "author": { "name": "ktiniatros", "key": "ktiniatros", "displayName": "Onoma Epitheto", "active": true, "timeZone": "Europe/Berlin" }, "body": "Hi,\r\n\r\nplz fix this. On android, you cannot change the opacity of a view neither with changing the property directly or with using setOpacity(newOpacity) method.\r\n\r\nThank you in advance.\r\n\r\nregards,", "updateAuthor": { "name": "ktiniatros", "key": "ktiniatros", "displayName": "Onoma Epitheto", "active": true, "timeZone": "Europe/Berlin" }, "created": "2012-02-28T07:04:15.000+0000", "updated": "2012-02-28T07:04:15.000+0000" }, { "id": "184996", "author": { "name": "stellis", "key": "stellis", "displayName": "Stephen Tellis", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I was able to reproduce this with:\r\n\r\nTiStudio 1.0.9 GA\r\nSDK 1.8.2 GA\r\n\r\non Mac OS 10.7", "updateAuthor": { "name": "stellis", "key": "stellis", "displayName": "Stephen Tellis", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-03-05T06:13:55.000+0000", "updated": "2012-03-05T06:13:55.000+0000" }, { "id": "216025", "author": { "name": "jyounus", "key": "jyounus", "displayName": "Junaid Younus", "active": true, "timeZone": "Europe/London" }, "body": "Tested on a Samsung Galaxy S2 using TiSDK 2.2.0v20120821095711, issue #2 still valid, issue #1 seems to be fixed. \r\n\r\n{code}\r\nvar win = Ti.UI.createWindow({backgroundColor: 'white'});\r\n\r\nvar view = Ti.UI.createView({\r\n width: 100,\r\n height: 100,\r\n backgroundColor: 'red',\r\n opacity: 0\r\n});\r\n\r\nwin.addEventListener('click', function(e)\r\n{\r\n Ti.API.info('Should be animating now.');\r\n \r\n view.animate({\r\n opacity: 0.6,\r\n duration: 1\r\n }, function(){\r\n Ti.API.info('Before (should be 0.6): ' + view.opacity);\r\n Ti.API.info('Setting opacity');\r\n view.setOpacity(1);\r\n Ti.API.info('After opacity (should be 1): ' + view.opacity);\r\n });\r\n});\r\n\r\nwin.add(view);\r\nwin.open();\r\n{code}", "updateAuthor": { "name": "jyounus", "key": "jyounus", "displayName": "Junaid Younus", "active": true, "timeZone": "Europe/London" }, "created": "2012-08-24T10:49:27.000+0000", "updated": "2012-08-24T10:49:27.000+0000" }, { "id": "294120", "author": { "name": "sunila", "key": "sunila", "displayName": "Sunila", "active": true, "timeZone": "Asia/Kolkata" }, "body": "I cannot reproduce the problem, both the setter and the property works.\r\nHere is the sample I tried\r\n\r\n var win = Ti.UI.createWindow({backgroundColor: 'white'});\r\n\t \r\n\tvar view = Ti.UI.createView({\r\n\t width: 100,\r\n\t height: 100,\r\n\t backgroundColor: 'red',\r\n\t opacity: 0\r\n\t});\r\n\t \r\n\twin.addEventListener('click', function(e)\r\n\t{\r\n\t view.animate({\r\n\t opacity: 0.3,\r\n\t duration: 1\r\n\t });\r\n\t});\r\n\t\r\n\tview.addEventListener('click', function(e)\r\n\t{\r\n view.opacity=1;\r\n e.cancelBubble=true;\r\n\t });\r\n\t \r\n\twin.add(view);\r\n\twin.open();", "updateAuthor": { "name": "sunila", "key": "sunila", "displayName": "Sunila", "active": true, "timeZone": "Asia/Kolkata" }, "created": "2014-02-21T15:15:42.000+0000", "updated": "2014-02-21T15:15:42.000+0000" }, { "id": "415915", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as I am unable to reproduce this issue with the following environment;\r\nPixel (7.1)\r\nMacOS 10.11.6 (15G31)\r\nStudio 4.8.1.201612050850\r\nTi SDK 6.0.3 GA\r\nAppc NPM 4.2.8\r\nAppc CLI 6.1.0\r\nTi CLI 5.0.11\r\nAlloy 1.9.5\r\nArrow 1.10.1\r\nXcode 8.2 (8C38)\r\nNode v4.6.0\r\nJava 1.7.0_80", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-03-27T20:12:51.000+0000", "updated": "2017-03-27T20:12:51.000+0000" } ], "maxResults": 8, "total": 8, "startAt": 0 } } }