[ALOY-1056] Cannot set onTintColor attribute/property in XML markup
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2014-06-20T19:13:28.000+0000 |
Affected Version/s | Alloy 1.4.0 |
Fix Version/s | Alloy 1.5.0 |
Components | XML |
Labels | qe-closed-3.4.0, qe-manualtest, qe-testadded |
Reporter | Benjamin Hatfield |
Assignee | Feon Sua Xin Miao |
Created | 2014-06-19T21:48:24.000+0000 |
Updated | 2014-08-20T10:35:20.000+0000 |
Description
*Preface* Not sure if this is an Alloy bug or we should not prefix property names with "on" in the Titanium SDK. *Description* Titanium SDK 3.3.0 introduces a new property for iOS that changes the color of the button when it is switched on: http://docs.appcelerator.com/titanium/latest/#!/api/Titanium.UI.Switch-property-onTintColor When using this property in Alloy XML markup, Alloy thinks it's an event. Property works fine in TSS or Controller code. *REPRODUCTION and RESULTS* The code below fails in the simulator with this error: {noformat} [ERROR] : Script Error { [ERROR] : backtrace = "#0 () at file:///Users/bhatfield/Library/Application%20Support/iPhone%20Simulator/7.0.3/Applications/4D9D3D70-9C78-4444-8A90-3C0277E07381/TestNewApis.app/alloy.js:232"; [ERROR] : line = 34; [ERROR] : message = "Can't find variable: green"; [ERROR] : name = ReferenceError; [ERROR] : sourceId = 268417408; [ERROR] : sourceURL = "file:///Users/bhatfield/Library/Application%20Support/iPhone%20Simulator/7.0.3/Applications/4D9D3D70-9C78-4444-8A90-3C0277E07381/TestNewApis.app/alloy/controllers/index.js"; [ERROR] : } {noformat} *Test Case:* {noformat}Attachments
File | Date | Size |
---|---|---|
switch_off.png | 2014-06-20T08:26:58.000+0000 | 34238 |
switch_on.png | 2014-06-20T08:26:58.000+0000 | 33292 |