{ "id": "160633", "key": "TIMOB-23487", "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": null, "resolutiondate": null, "created": "2016-06-01T00:47:20.000+0000", "priority": null, "labels": [ "windows" ], "versions": [], "issuelinks": [], "assignee": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "updated": "2016-06-10T01:09:35.000+0000", "status": { "description": "The issue is open and ready for the assignee to start work on it.", "name": "Open", "id": "1", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [], "description": "h2. Problem\r\n\r\nAll the methods from alloy (onClick, onBlur, onReturn, etc.) are returning a different e.source.apiName on Windows 8.1 & 10 then iOS & Android. Windows is returning Titanium.UI., while iOS & Android return Ti.Ui.\r\n\r\nh2. Expected\r\n\r\nWindows perform the same as iOS & Android.\r\n\r\nh3. Sample Code\r\n\r\n{code:lang=javascript|title=index.js}\r\nfunction doClick(e) {\r\n alert(e.source.apiName);\r\n}\r\n\r\n$.index.open();\r\n{code}\r\n\r\n{code:lang=xml|title=index.xml}\r\n\r\n\t\r\n\t\t\r\n\t\r\n\r\n{code}\r\n\r\n{code:lang=css|title=index.tss}\r\n\".container\": {\r\n\tbackgroundColor:\"white\"\r\n}\r\n\r\n\"Label\": {\r\n\twidth: Ti.UI.SIZE,\r\n\theight: Ti.UI.SIZE,\r\n\tcolor: \"#000\"\r\n}\r\n\r\n\"#label\": {\r\n\tfont: {\r\n\t\tfontSize: 12\r\n\t}\r\n}\r\n{code}", "attachment": [], "flagged": false, "summary": "Windows: e.source.apiName inconsistancy with iOS & Android", "creator": { "name": "kdclaw3@gmail.com", "key": "kdclaw3@gmail.com", "displayName": "Dee Clawson", "active": true, "timeZone": "America/New_York" }, "subtasks": [], "reporter": { "name": "kdclaw3@gmail.com", "key": "kdclaw3@gmail.com", "displayName": "Dee Clawson", "active": true, "timeZone": "America/New_York" }, "environment": "Ti SDK: 5.3.0.v20160523083840", "comment": { "comments": [ { "id": "387383", "author": { "name": "nsalahin", "key": "nsalahin", "displayName": "Nazmus Salahin", "active": true, "timeZone": "Asia/Dhaka" }, "body": "Hello,\r\n\r\nThanks for creating this ticket. It will be appreciated if you provide test code and step to reproduce this issue. Once we are able to reproduce the issue we will escalate the ticket.\r\n\r\nThanks in advance", "updateAuthor": { "name": "nsalahin", "key": "nsalahin", "displayName": "Nazmus Salahin", "active": true, "timeZone": "Asia/Dhaka" }, "created": "2016-06-02T05:42:11.000+0000", "updated": "2016-06-02T05:42:11.000+0000" }, { "id": "387432", "author": { "name": "kdclaw3@gmail.com", "key": "kdclaw3@gmail.com", "displayName": "Dee Clawson", "active": true, "timeZone": "America/New_York" }, "body": "@nsalahin Code inserted into description. ", "updateAuthor": { "name": "kdclaw3@gmail.com", "key": "kdclaw3@gmail.com", "displayName": "Dee Clawson", "active": true, "timeZone": "America/New_York" }, "created": "2016-06-02T17:33:23.000+0000", "updated": "2016-06-02T17:33:23.000+0000" }, { "id": "387437", "author": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "body": "FYI, \"Titanium.UI.\" and \"Ti.UI.\" are same thing.", "updateAuthor": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "created": "2016-06-02T17:59:55.000+0000", "updated": "2016-06-02T17:59:55.000+0000" }, { "id": "387438", "author": { "name": "kdclaw3@gmail.com", "key": "kdclaw3@gmail.com", "displayName": "Dee Clawson", "active": true, "timeZone": "America/New_York" }, "body": "@sdarda \"Titanium.UI.Label\" !== \"Ti.UI.Label\"\r\n\r\nThe namespace may be the same. Yaw'll are outputting it as text though.", "updateAuthor": { "name": "kdclaw3@gmail.com", "key": "kdclaw3@gmail.com", "displayName": "Dee Clawson", "active": true, "timeZone": "America/New_York" }, "created": "2016-06-02T18:00:00.000+0000", "updated": "2016-06-02T18:00:58.000+0000" }, { "id": "387439", "author": { "name": "kdclaw3@gmail.com", "key": "kdclaw3@gmail.com", "displayName": "Dee Clawson", "active": true, "timeZone": "America/New_York" }, "body": "@sdarda FYI. You (Appcelerator) provide an event method, the emitter on that event method outputs JSON. Somewhere in that JSON you have a key of \"source\". Under that key is another key \"apiName\". The bug I have pointed out addresses this key value pair. It is different in ios/android from windows. In ios/android you (Appcelerator) use the string \"Ti\", in windows you (Appcelerator) use the string \"Titanium\".", "updateAuthor": { "name": "kdclaw3@gmail.com", "key": "kdclaw3@gmail.com", "displayName": "Dee Clawson", "active": true, "timeZone": "America/New_York" }, "created": "2016-06-02T18:06:42.000+0000", "updated": "2016-06-02T18:06:42.000+0000" }, { "id": "387586", "author": { "name": "nsalahin", "key": "nsalahin", "displayName": "Nazmus Salahin", "active": true, "timeZone": "Asia/Dhaka" }, "body": "Hello,\r\nI am able to reproduce this issue with given code and given steps.\r\n*Steps:*\r\n1. Create a default alloy project with given code for Windows and Android phone.\r\n2. Build and run the app on windows phone and click the label. {{e.source.apiName}} is returned in the alert as {{Titanium.UI.Label}}\r\n[Screenshot|https://i.imgsafe.org/3bd986b073.png]\r\n3. Build and run the app on android phone and click the label. {{e.source.apiName}} is returned in the alert as {{Ti.UI.Label}}\r\n[Screenshot|https://i.imgsafe.org/3be0287909.png]\r\nThanks\r\n\r\n*Environment*:\r\n\r\n*Device info:* HTC One(android 4.4.3), Windows Phone Emulator (Windows 8.1)\r\n*Node.js Version:* 0.12.7\r\n*npm Version:* 2.11.3\r\n*Titanium SDKs:* 5.4.0.v20160509133737\r\n*Java Development Kit Version:* 1.8.0_73\r\n*Titanium CLI Version:* 5.0.5\r\n*Appcelerator CLI Version:* 5.2.2\r\n*Appcelerator Studio:* 4.5.0\r\n\r\n", "updateAuthor": { "name": "nsalahin", "key": "nsalahin", "displayName": "Nazmus Salahin", "active": true, "timeZone": "Asia/Dhaka" }, "created": "2016-06-05T05:55:02.000+0000", "updated": "2016-06-05T05:55:02.000+0000" } ], "maxResults": 6, "total": 6, "startAt": 0 } } }