Problem
All 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.
Expected
Windows perform the same as iOS & Android.
Sample Code
function doClick(e) {
alert(e.source.apiName);
}
$.index.open();
<Alloy>
<Window class="container">
<Label id="label" onClick="doClick">Hello, World</Label>
</Window>
</Alloy>
".container": {
backgroundColor:"white"
}
"Label": {
width: Ti.UI.SIZE,
height: Ti.UI.SIZE,
color: "#000"
}
"#label": {
font: {
fontSize: 12
}
}
Hello, Thanks 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. Thanks in advance
@nsalahin Code inserted into description.
FYI, "Titanium.UI." and "Ti.UI." are same thing.
@sdarda "Titanium.UI.Label" !== "Ti.UI.Label" The namespace may be the same. Yaw'll are outputting it as text though.
@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".
Hello, I am able to reproduce this issue with given code and given steps. *Steps:* 1. Create a default alloy project with given code for Windows and Android phone. 2. Build and run the app on windows phone and click the label.
e.source.apiName
is returned in the alert asTitanium.UI.Label
[Screenshot](https://i.imgsafe.org/3bd986b073.png) 3. Build and run the app on android phone and click the label.e.source.apiName
is returned in the alert asTi.UI.Label
[Screenshot](https://i.imgsafe.org/3be0287909.png) Thanks *Environment*: *Device info:* HTC One(android 4.4.3), Windows Phone Emulator (Windows 8.1) *Node.js Version:* 0.12.7 *npm Version:* 2.11.3 *Titanium SDKs:* 5.4.0.v20160509133737 *Java Development Kit Version:* 1.8.0_73 *Titanium CLI Version:* 5.0.5 *Appcelerator CLI Version:* 5.2.2 *Appcelerator Studio:* 4.5.0