{ "id": "167476", "key": "TIMOB-24660", "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": "17608", "name": "Release 6.1.0", "archived": false, "released": true, "releaseDate": "2017-05-26" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2017-05-09T23:26:33.000+0000", "created": "2017-05-05T12:23:06.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [ "merge-6.1.0" ], "versions": [ { "id": "16980", "description": "New V8", "name": "Release 6.0.0", "archived": false, "released": true, "releaseDate": "2016-11-15" } ], "issuelinks": [ { "id": "54831", "type": { "id": "10001", "name": "Cloners", "inward": "is cloned into", "outward": "is cloned from" }, "outwardIssue": { "id": "165026", "key": "TIMOB-24256", "fields": { "summary": "Android: openPhotoGallery is not working at all on SDK 6.0.0.GA,6.0.1.GA", "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": "Critical", "id": "1" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-05-10T16:59:18.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": "{{content://com.android.providers.downloads.documents}} is currently not supported in {{TitaniumBlob.java}}, this prevents obtaining file information for images selected in the {{Downloads}} category of {{Titanium.Media.openPhotoGallery}}.\r\n\r\n*TEST CASE*\r\n{code:js}\r\nvar w = Ti.UI.createWindow({backgroundColor : 'grey'}),\r\n b = Titanium.UI.createButton({\r\n title : 'OPEN GALLERY',\r\n top : '10dp'\r\n }),\r\n iv = Ti.UI.createImageView({\r\n top : '65dp',\r\n width : '95%'\r\n }),\r\n sp = 'android.permission.READ_EXTERNAL_STORAGE';\r\n\r\nfunction openGallery() {\r\n Ti.Media.openPhotoGallery({\r\n mediaTypes : [Ti.Media.MEDIA_TYPE_PHOTO],\r\n success: function(e) {\r\n iv.height = e.media.height * (iv.rect.width / e.media.width);\r\n iv.image = e.media;\r\n\r\n alert('filename: ' + e.media.file.name);\r\n alert('filesize: ' + e.media.length);\r\n },\r\n error: function(e) {\r\n Ti.API.error(JSON.stringify(e));\r\n }\r\n });\r\n}\r\n\r\nb.addEventListener('click', function(e) {\r\n if (Ti.Android.hasPermission(sp)) {\r\n openGallery();\r\n } else {\r\n Ti.Android.requestPermissions([sp], function(e) {\r\n if (e.success) {\r\n openGallery();\r\n } else {\r\n Ti.API.info('ERROR: ' + e.error);\r\n }\r\n });\r\n }\r\n});\r\n\r\nw.add(b);\r\nw.add(iv);\r\n\r\nw.open();\r\n{code}", "attachment": [], "flagged": false, "summary": "Android: openPhotoGallery is not working for downloads", "creator": { "name": "gmathews", "key": "gmathews", "displayName": "Gary Mathews", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "dfoxinator", "key": "dfoxinator", "displayName": "David Fox", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "closedSprints": [ { "id": 787, "state": "closed", "name": "2017 Sprint 01 SDK", "startDate": "2016-12-31T02:15:33.446Z", "endDate": "2017-01-14T02:15:00.000Z", "completeDate": "2017-01-15T00:00:19.006Z", "originBoardId": 114 }, { "id": 889, "state": "closed", "name": "2017 Sprint 10 SDK", "startDate": "2017-05-08T00:27:49.740Z", "endDate": "2017-05-22T00:27:00.000Z", "completeDate": "2017-05-22T02:41:01.011Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "419168", "author": { "name": "gmathews", "key": "gmathews", "displayName": "Gary Mathews", "active": true, "timeZone": "America/Los_Angeles" }, "body": "master: https://github.com/appcelerator/titanium_mobile/pull/9021", "updateAuthor": { "name": "gmathews", "key": "gmathews", "displayName": "Gary Mathews", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2017-05-05T12:41:57.000+0000", "updated": "2017-05-05T12:41:57.000+0000" }, { "id": "419215", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Moved to 6.1.0. We will need a back port [~gmathews]", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2017-05-05T18:11:29.000+0000", "updated": "2017-05-05T18:11:29.000+0000" }, { "id": "419364", "author": { "name": "gmathews", "key": "gmathews", "displayName": "Gary Mathews", "active": true, "timeZone": "America/Los_Angeles" }, "body": "6_1_X: https://github.com/appcelerator/titanium_mobile/pull/9038", "updateAuthor": { "name": "gmathews", "key": "gmathews", "displayName": "Gary Mathews", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2017-05-09T16:10:04.000+0000", "updated": "2017-05-09T16:10:04.000+0000" }, { "id": "419482", "author": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified fix on SDK version 6.2.0.v20170510084833 and 6.1.0.v20170509170935. Test and other information can be found at:\r\nMaster:https://github.com/appcelerator/titanium_mobile/pull/9021\r\n6_1_X:https://github.com/appcelerator/titanium_mobile/pull/9038", "updateAuthor": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2017-05-10T16:59:10.000+0000", "updated": "2017-05-10T16:59:10.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }