{ "id": "146369", "key": "TIMOB-18765", "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": "16593", "description": "Release 4.0.0", "name": "Release 4.0.0", "archived": false, "released": true, "releaseDate": "2015-05-21" }, { "id": "16723", "description": "Windows Platform Support, ListView updates, Vector overlays in maps", "name": "Release 4.1.0", "archived": false, "released": true, "releaseDate": "2015-07-08" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2015-05-15T18:37:55.000+0000", "created": "2015-03-30T01:32:38.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "filesystem", "webview" ], "versions": [ { "id": "16704", "description": "Release 3.5.0", "name": "Release 3.5.0", "archived": false, "released": true, "releaseDate": "2015-01-13" } ], "issuelinks": [ { "id": "47657", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "inwardIssue": { "id": "147702", "key": "TIMOB-18890", "fields": { "summary": "iOS: ImageView is not rendering remote urls", "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 } } } }, { "id": "47709", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "inwardIssue": { "id": "147743", "key": "TIMOB-18897", "fields": { "summary": "iOS: Issue with 4.0 - Ti.UI.Button.Image is not working", "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 } } } }, { "id": "47656", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "inwardIssue": { "id": "147684", "key": "TIMOB-18889", "fields": { "summary": "iOS: ImageView with Remote URLs broken", "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": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "47658", "type": { "id": "10122", "name": "Gantt: start-finish", "inward": "is triggered by", "outward": "is triggering" }, "outwardIssue": { "id": "147684", "key": "TIMOB-18889", "fields": { "summary": "iOS: ImageView with Remote URLs broken", "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": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2015-05-18T17:02:04.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": "h6.Description:\r\nSince Ti SDK 3.5.0, WebView does no recognise the html file when using Ti.sourceDirectory File system, if there is space in app name. \r\n\r\nh6.Reproduce:\r\n1. Create a classic project named \"Simple Test\" (with space)\r\n2. Create a folder named \"html\" under Resource folder.\r\n3. Create a simple html file name \"comingSoon.html\", like following\r\n{code:title=comingSoon.html}\r\n\r\n\t\r\n\t\tHello World!\r\n\t\r\n\t\r\n\t\t
\r\n\t\t

Content to follow soon

\r\n\t\t
\r\n\t\r\n\r\n{code} \r\n4.Add following code into app.js file\r\n{code:title=app.js}\r\nar win = Ti.UI.createWindow({\r\n\tbackgroundColor: 'white'\r\n});\r\n\r\nvar f = Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory,'/html/comingSoon.html');\r\nif (f.exists()) {\r\n\tvar contents = f.read();\r\n\talert('Output the file:'+contents.text);\r\n} else {\r\n\tTi.API.info(\"No such file!\");\r\n}\r\n\r\nvar URL = Ti.Filesystem.resourcesDirectory + '/html/comingSoon.html';\r\n\r\nvar wv = Ti.UI.createWebView({\r\n\ttop: 30,\r\n\turl: URL\r\n});\r\n\r\nwin.add(wv);\r\nwin.open();\r\n{code}\r\n\r\nh6.Expect Result:\r\nThe webview should display normally. \r\n\r\nh6.Actual Result:\r\nThe error pop out in console log:\r\n*\"couldn't load URL: app://com.cocoafish.sliangPush/Users/shuoliang/Library/Developer/CoreSimulator/Devices/EA379BD7-8255-4555-9A89-79678C7C68EB/data/Containers/Bundle/Application/BCD65E99-C189-4889-9177-CD870924377D/Simple%20Push.app/html/comingSoon.html\"*\r\n\r\nh6.Note:\r\n1. No such problem in SDK 3.4.1\r\n2. Change the app name without space, problem gone.", "attachment": [], "flagged": false, "summary": "iOS: WebView do not recognize local HTML File using Ti.sourceDirectory if Project Name has a space", "creator": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "subtasks": [], "reporter": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "environment": "TI SDK 3.5.1\r\nIOS 8.2", "closedSprints": [ { "id": 371, "state": "closed", "name": "2015 Sprint 08 SDK", "startDate": "2015-04-11T00:00:49.626Z", "endDate": "2015-04-24T12:00:00.000Z", "completeDate": "2015-04-28T15:02:06.073Z", "originBoardId": 114 }, { "id": 404, "state": "closed", "name": "2015 Sprint 10 SDK", "startDate": "2015-05-09T00:00:53.391Z", "endDate": "2015-05-23T00:00:00.000Z", "completeDate": "2015-05-25T14:55:16.386Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "350330", "author": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "body": "PR: https://github.com/appcelerator/titanium_mobile/pull/6794\r\n4_0_X PR: https://github.com/appcelerator/titanium_mobile/pull/6795", "updateAuthor": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-04-22T01:28:44.000+0000", "updated": "2015-04-22T01:28:44.000+0000" }, { "id": "350678", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "master PR merged. Backport PR not merged since ticket has no labels to indicate it needs to be backported", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-04-24T17:32:01.000+0000", "updated": "2015-04-24T17:32:01.000+0000" }, { "id": "350732", "author": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "body": "[~vduggal], sorry missed that. Ticket updated accordingly, can you please merge? Thanks.", "updateAuthor": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-04-24T23:48:53.000+0000", "updated": "2015-04-24T23:48:53.000+0000" }, { "id": "350747", "author": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "body": "[~sliang] 4_0_X once the back port is merged.", "updateAuthor": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-04-25T16:51:56.000+0000", "updated": "2015-04-25T16:51:56.000+0000" }, { "id": "350874", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Backport merged", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-04-27T16:36:14.000+0000", "updated": "2015-04-27T16:36:14.000+0000" }, { "id": "351195", "author": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "body": "Verified using:\r\n\r\nMac OSX 10.10.3\r\nAppc Studio: 4.0.0.201504272049\r\nTitanium SDK build: 4.0.0.v20150427093413\r\nAppc CLI (NPM): 0.3.51\r\nAppc CLI (Registry): 0.2.273\r\niPhone 5s (8.0.2)\r\n\r\nWhen the project name has a space the local HTML file loads with no issues\r\n\r\nClosing ticket", "updateAuthor": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "created": "2015-04-29T23:43:03.000+0000", "updated": "2015-04-29T23:43:03.000+0000" }, { "id": "351643", "author": { "name": "lawrence.wilson@abannan.com", "key": "lawrence.wilson@abannan.com", "displayName": "Lawrence Wilson", "active": true, "timeZone": "Europe/London" }, "body": "The change implemented in TiUtils.m has affected the ImageView image property which now will not display an image if there is a space in the image name.\r\n\r\n{{}}\r\n\r\nThis displays the image in 4.0.0.RC but not in 4.0.0.RC2", "updateAuthor": { "name": "lawrence.wilson@abannan.com", "key": "lawrence.wilson@abannan.com", "displayName": "Lawrence Wilson", "active": true, "timeZone": "Europe/London" }, "created": "2015-05-05T13:01:23.000+0000", "updated": "2015-05-05T13:01:23.000+0000" }, { "id": "351665", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Please see latest comment on possible regression caused by this change.", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-05-05T17:01:10.000+0000", "updated": "2015-05-05T17:01:10.000+0000" }, { "id": "351750", "author": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Regression addressed here:\r\nMaster: https://github.com/appcelerator/titanium_mobile/pull/6821\r\n4_0_X: https://github.com/appcelerator/titanium_mobile/pull/6822", "updateAuthor": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-06T04:04:39.000+0000", "updated": "2015-05-06T04:04:39.000+0000" }, { "id": "352094", "author": { "name": "athorne", "key": "athorne", "displayName": "Alex Bernier", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Remote images are broken on master now. I believe [this is the cause|https://github.com/cheekiatng/titanium_mobile/commit/484683cb34757b8d697fd56c4cf1691091f3a51d] (only taking path of a url):\r\n\r\niphone/Classes/TiUIImageView.m\r\n{code}\r\n-\t\tNSURL *url_ = [TiUtils toURL:[img absoluteString] proxy:self.proxy];\r\n+\t\tNSURL *url_ = [TiUtils toURL:[img path] proxy:self.proxy];\r\n{code}", "updateAuthor": { "name": "athorne", "key": "athorne", "displayName": "Alex Bernier", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-05-08T23:08:56.000+0000", "updated": "2015-05-08T23:08:56.000+0000" }, { "id": "352095", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Reopening based on comments.", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-05-08T23:11:03.000+0000", "updated": "2015-05-08T23:11:03.000+0000" }, { "id": "352106", "author": { "name": "zo0m", "key": "zo0m", "displayName": "Igor Kalashnikov", "active": true, "timeZone": "Europe/Helsinki" }, "body": "Hi all,\r\n\r\ndoes that commit explain this bug:\r\n!https://pp.vk.me/c625823/v625823842/30a41/fqhPXEwWTBg.jpg|height=200!\r\n\r\npaths to images are OK,\r\n\r\niOS displays them if I use backgroundImage attribute like this:\r\n{code}{code}\r\n, but if I use:\r\n{code}{code}\r\nI see that stubs.", "updateAuthor": { "name": "zo0m", "key": "zo0m", "displayName": "Igor Kalashnikov", "active": true, "timeZone": "Europe/Helsinki" }, "created": "2015-05-09T07:02:29.000+0000", "updated": "2015-05-09T07:02:29.000+0000" }, { "id": "352107", "author": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "body": "[~zo0m], yes this is most likely the cause. sorry about that we will fix this as soon as we can. And thanks [~athorne] for spotting this.", "updateAuthor": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-09T07:41:14.000+0000", "updated": "2015-05-09T07:42:38.000+0000" }, { "id": "352111", "author": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Master PR: https://github.com/appcelerator/titanium_mobile/pull/6830\r\n4_0_X PR: https://github.com/appcelerator/titanium_mobile/pull/6831\r\n\r\nh4. Additional test cases\r\n1. Set image in imageView with a remote url image\r\n2. Set image in imageView with a local url image\r\n3. Set image in imageView with a local url image that contains whitespace in filename\r\n\r\nh4. Expected result\r\nImage will show in all test cases\r\n", "updateAuthor": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-09T15:15:06.000+0000", "updated": "2015-05-09T15:15:06.000+0000" }, { "id": "352113", "author": { "name": "athorne", "key": "athorne", "displayName": "Alex Bernier", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Thank you, [~cng], for the quick fix!", "updateAuthor": { "name": "athorne", "key": "athorne", "displayName": "Alex Bernier", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-05-09T17:35:22.000+0000", "updated": "2015-05-09T17:35:31.000+0000" }, { "id": "352134", "author": { "name": "lawrence.wilson@abannan.com", "key": "lawrence.wilson@abannan.com", "displayName": "Lawrence Wilson", "active": true, "timeZone": "Europe/London" }, "body": "Are you sure you have tested number 3?\r\n\r\nThe ImageView image property will not display an image if there is a space in the image name.\r\n\r\n{{}}\r\n\r\nThis displays the image in 4.0.0.RC but not in 4.0.0.RC3", "updateAuthor": { "name": "lawrence.wilson@abannan.com", "key": "lawrence.wilson@abannan.com", "displayName": "Lawrence Wilson", "active": true, "timeZone": "Europe/London" }, "created": "2015-05-11T07:32:56.000+0000", "updated": "2015-05-11T07:32:56.000+0000" }, { "id": "352135", "author": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Yes I have tested it for this pr. It will be verified again when reviewed before merging :)", "updateAuthor": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-11T08:00:11.000+0000", "updated": "2015-05-11T08:00:11.000+0000" }, { "id": "352160", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Above PR's closed\r\nNew PR's\r\nmaster - https://github.com/appcelerator/titanium_mobile/pull/6833\r\n4_0_X - https://github.com/appcelerator/titanium_mobile/pull/6834", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-11T16:34:32.000+0000", "updated": "2015-05-11T16:34:32.000+0000" }, { "id": "352189", "author": { "name": "athorne", "key": "athorne", "displayName": "Alex Bernier", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Thank you, everyone!", "updateAuthor": { "name": "athorne", "key": "athorne", "displayName": "Alex Bernier", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-05-11T20:11:28.000+0000", "updated": "2015-05-11T20:11:28.000+0000" }, { "id": "352516", "author": { "name": "lawrence.wilson@abannan.com", "key": "lawrence.wilson@abannan.com", "displayName": "Lawrence Wilson", "active": true, "timeZone": "Europe/London" }, "updateAuthor": { "name": "lawrence.wilson@abannan.com", "key": "lawrence.wilson@abannan.com", "displayName": "Lawrence Wilson", "active": true, "timeZone": "Europe/London" }, "created": "2015-05-14T08:27:34.000+0000", "updated": "2015-05-14T08:27:34.000+0000" }, { "id": "352525", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "[~skateboss] Those two tickets are duplicate of this. So, to confirm, these two test cases fail:\r\n\r\n{code}\r\n \r\n{code}\r\n\r\nand:\r\n\r\nfile:///Users/abannanmacmini/Library/Developer/CoreSimulator/Devices/192189D6-2D20-4572-B050-08C2DEB45E78/data/Containers/Data/Application/A80D5311-494A-435D-84A6-3D352E77C638/Library/Caches/abreader/cache/7fe480f7-0a05-41d1-a837-5ab900e583fd/5b6ae379-f7f0-4a70-b5ad-cd4a7759a8d6/OverlayResources/InDesign_BNDLR_RSRC21316-1764919231/members_State%201_602_Content_L.png\r\n", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-05-14T14:12:05.000+0000", "updated": "2015-05-14T14:12:05.000+0000" }, { "id": "352526", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Spaces in image names or path to image work fine. I've also tested setting the image to a blob or file directly and that also works. The reason nativePath property of the file no longer works with the image property in certain cases is because nativePath returns the path in the encoded form and then ImageView re-encodes it to a location that is invalid (Essentially space->%20->%2520). So the workaround is to use the resolve() method on the File Object instead of the nativePath property. \r\n\r\nTest case below. \r\n{code}\r\nvar win = Titanium.UI.createWindow({backgroundColor:'white',layout:'vertical'});\r\n\r\nvar toolsView = Ti.UI.createView({height:Ti.UI.SIZE,width:Ti.UI.SIZE,layout:'horizontal',top:20})\r\n\r\nvar b1 = Ti.UI.createButton({title:'STRING',left:5,borderColor:'black',borderWidth:1});\r\nvar b2 = Ti.UI.createButton({title:'FILE',left:5,borderColor:'black',borderWidth:1});\r\nvar b3 = Ti.UI.createButton({title:'BLOB',left:5,borderColor:'black',borderWidth:1});\r\nvar b4 = Ti.UI.createButton({title:'PATH',left:5,borderColor:'black',borderWidth:1});\r\n\r\ntoolsView.add(b1);\r\ntoolsView.add(b2);\r\ntoolsView.add(b3);\r\ntoolsView.add(b4);\r\nwin.add(toolsView);\r\n\r\nvar imgContainer = Ti.UI.createView();\r\nwin.add(imgContainer);\r\nwin.open();\r\n\r\n\r\nb1.addEventListener('click',function(){\r\n\timgContainer.removeAllChildren();\r\n\timgContainer.backgroundColor = 'black';\r\n\tvar imgView = Ti.UI.createImageView({image:'images/cloud copy.png'});\r\n\timgContainer.add(imgView);\r\n})\r\n\r\nb2.addEventListener('click',function(){\r\n\timgContainer.removeAllChildren();\r\n\timgContainer.backgroundColor = 'green';\r\n\tvar file = Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory,'images/cloud copy.png');\r\n\tvar imgView = Ti.UI.createImageView({image:file});\r\n\timgContainer.add(imgView);\r\n})\r\n\r\nb3.addEventListener('click',function(){\r\n\timgContainer.removeAllChildren();\r\n\timgContainer.backgroundColor = 'yellow';\r\n\tvar file = Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory,'images/cloud copy.png').read();\r\n\tvar imgView = Ti.UI.createImageView({image:file});\r\n\timgContainer.add(imgView);\r\n})\r\n\r\nb4.addEventListener('click',function(){\r\n\timgContainer.removeAllChildren();\r\n\timgContainer.backgroundColor = 'red';\r\n\tvar file = Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory,'images/cloud copy.png').resolve();\r\n\tvar imgView = Ti.UI.createImageView({image:file});\r\n\timgContainer.add(imgView);\r\n})\r\n{code}", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-14T15:18:44.000+0000", "updated": "2015-05-14T15:18:44.000+0000" }, { "id": "352580", "author": { "name": "ewieber", "key": "ewieber", "displayName": "Eric Wieber", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Reopening; I still encounter the \"image with space in name not displaying\" issue with Tab icons in Alloy projects:\r\n\r\n*Steps to reproduce issue*:\r\n1. Create a new Alloy 2 Tab project\r\n2. Modify the first tab in the {{index.xml}} to use {{icon=\"KS_nav ui.png\"}}\r\n3. Rename the {{KS_nav_ui.png}} file to {{KS_nav ui.png}}\r\n4. Run the project\r\n\r\n*Actual Results*:\r\nThe icon for the first tab does not show up\r\n\r\n*Expected Results*:\r\nThe icon is displayed\r\n\r\nI used:\r\nStudio 4.0.0.201505121820\r\nTi SDK 4.0.0.RC4\r\nAppc NPM 0.3.55\r\nAppc CLI 0.2.285\r\nTi CLI 4.0.0-beta8\r\nAlloy 1.6.0-beta4\r\n\r\non iPhone 6 Simulator, iOS 8.3", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-05-14T21:11:24.000+0000", "updated": "2015-05-14T22:04:40.000+0000" }, { "id": "352582", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "[~ewieber] What does the generated code look like?", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-05-14T21:27:05.000+0000", "updated": "2015-05-14T21:27:05.000+0000" }, { "id": "352627", "author": { "name": "lawrence.wilson@abannan.com", "key": "lawrence.wilson@abannan.com", "displayName": "Lawrence Wilson", "active": true, "timeZone": "Europe/London" }, "body": "@Ingo My generated code from Alloy produces the following:\r\n\r\n$.__views.__alloyId1 = Ti.UI.createImageView({\r\n image: \"/images/thumb%20P6.jpg\",\r\n id: \"__alloyId1\"\r\n});\r\n\r\n@Vishal - I have noticed that I can use {{resolve()}} as a workaround, but is this acceptable without being notified about the change and what about {{backgroundImage}} properties - should there be such an inconsistency?", "updateAuthor": { "name": "lawrence.wilson@abannan.com", "key": "lawrence.wilson@abannan.com", "displayName": "Lawrence Wilson", "active": true, "timeZone": "Europe/London" }, "created": "2015-05-15T08:18:56.000+0000", "updated": "2015-05-15T08:18:56.000+0000" }, { "id": "352636", "author": { "name": "ewieber", "key": "ewieber", "displayName": "Eric Wieber", "active": false, "timeZone": "America/Los_Angeles" }, "body": "[~ingo] Here is my generated code for the entire Tabgroup/Alloy view:\r\nThe tab that does show the icon seems to match the tab that does not show the icon.\r\n{code}\r\nfunction __processArg(obj, key) {\r\n var arg = null;\r\n if (obj) {\r\n arg = obj[key] || null;\r\n delete obj[key];\r\n }\r\n return arg;\r\n}\r\n\r\nfunction Controller() {\r\n require(\"alloy/controllers/BaseController\").apply(this, Array.prototype.slice.call(arguments));\r\n this.__controllerPath = \"index\";\r\n this.args = arguments[0] || {};\r\n if (arguments[0]) {\r\n {\r\n __processArg(arguments[0], \"__parentSymbol\");\r\n }\r\n {\r\n __processArg(arguments[0], \"$model\");\r\n }\r\n {\r\n __processArg(arguments[0], \"__itemTemplate\");\r\n }\r\n }\r\n var $ = this;\r\n var exports = {};\r\n var __alloyId0 = [];\r\n $.__views.__alloyId2 = Ti.UI.createWindow({\r\n backgroundColor: \"#fff\",\r\n title: \"Tab 1\",\r\n id: \"__alloyId2\"\r\n });\r\n $.__views.__alloyId3 = Ti.UI.createLabel({\r\n width: Ti.UI.SIZE,\r\n height: Ti.UI.SIZE,\r\n color: \"#000\",\r\n font: {\r\n fontSize: 20,\r\n fontFamily: \"Helvetica Neue\"\r\n },\r\n textAlign: \"center\",\r\n text: \"I am Window 1\",\r\n id: \"__alloyId3\"\r\n });\r\n $.__views.__alloyId2.add($.__views.__alloyId3);\r\n $.__views.__alloyId1 = Ti.UI.createTab({\r\n window: $.__views.__alloyId2,\r\n title: \"Tab 1\",\r\n icon: \"KS_nav ui.png\",\r\n id: \"__alloyId1\"\r\n });\r\n __alloyId0.push($.__views.__alloyId1);\r\n $.__views.__alloyId5 = Ti.UI.createWindow({\r\n backgroundColor: \"#fff\",\r\n title: \"Tab 2\",\r\n id: \"__alloyId5\"\r\n });\r\n $.__views.__alloyId6 = Ti.UI.createLabel({\r\n width: Ti.UI.SIZE,\r\n height: Ti.UI.SIZE,\r\n color: \"#000\",\r\n font: {\r\n fontSize: 20,\r\n fontFamily: \"Helvetica Neue\"\r\n },\r\n textAlign: \"center\",\r\n text: \"I am Window 2\",\r\n id: \"__alloyId6\"\r\n });\r\n $.__views.__alloyId5.add($.__views.__alloyId6);\r\n $.__views.__alloyId4 = Ti.UI.createTab({\r\n window: $.__views.__alloyId5,\r\n title: \"Tab 2\",\r\n icon: \"views.png\",\r\n id: \"__alloyId4\"\r\n });\r\n __alloyId0.push($.__views.__alloyId4);\r\n $.__views.index = Ti.UI.createTabGroup({\r\n tabs: __alloyId0,\r\n id: \"index\"\r\n });\r\n $.__views.index && $.addTopLevelView($.__views.index);\r\n exports.destroy = function() {};\r\n _.extend($, $.__views);\r\n $.index.open();\r\n _.extend($, exports);\r\n}\r\n\r\nvar Alloy = require(\"alloy\"), Backbone = Alloy.Backbone, _ = Alloy._;\r\n\r\nmodule.exports = Controller;\r\n{code}", "updateAuthor": { "name": "ewieber", "key": "ewieber", "displayName": "Eric Wieber", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-15T15:41:18.000+0000", "updated": "2015-05-15T15:41:18.000+0000" }, { "id": "352639", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "PR's to address double encoding\r\nmaster - https://github.com/appcelerator/titanium_mobile/pull/6852\r\n4_0_X - https://github.com/appcelerator/titanium_mobile/pull/6853", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-15T16:15:36.000+0000", "updated": "2015-05-15T16:15:36.000+0000" }, { "id": "352870", "author": { "name": "ewieber", "key": "ewieber", "displayName": "Eric Wieber", "active": false, "timeZone": "America/Los_Angeles" }, "body": "I can no longer reproduce the \"image with space in name not displaying\" issue with Tab icons in Alloy projects\r\n\r\nMacOS 10.10.3\r\nStudio 4.0.0.201505170122\r\nTi SDK 4.0.0.v20150516200211\r\nAppc NPM 0.3.55\r\nCLI: 0.2.290\r\nTi CLI 4.0.0-beta9\r\nAlloy 1.6.0-beta4\r\nNode v0.10.37\r\nJava 1.7.0_45\r\n\r\nIcons for tabs correctly display.", "updateAuthor": { "name": "ewieber", "key": "ewieber", "displayName": "Eric Wieber", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-18T16:39:37.000+0000", "updated": "2015-05-18T16:39:37.000+0000" }, { "id": "352875", "author": { "name": "ewieber", "key": "ewieber", "displayName": "Eric Wieber", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing this ticket as it looks fixed.\r\n[~lawrence.wilson@abannan.com] Please comment if your issue is not resolved when using the above environment.", "updateAuthor": { "name": "ewieber", "key": "ewieber", "displayName": "Eric Wieber", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-05-18T17:02:04.000+0000", "updated": "2015-05-18T17:02:04.000+0000" } ], "maxResults": 30, "total": 30, "startAt": 0 } } }