[ALOY-311] Don't assign Ti.Android.MenuItem properties twice in parser
GitHub Issue | n/a |
---|---|
Type | Improvement |
Priority | Low |
Status | Resolved |
Resolution | Fixed |
Resolution Date | 2012-11-28T23:27:00.000+0000 |
Affected Version/s | 2012 Sprint 20 |
Fix Version/s | Alloy 0.3.3, 2012 Sprint 24 |
Components | XML |
Labels | n/a |
Reporter | Tony Lukasavage |
Assignee | Unknown |
Created | 2012-09-29T21:53:27.000+0000 |
Updated | 2018-03-07T22:26:13.000+0000 |
Description
In the Ti.Android.MenuItem.js parser, only 4 properties are processed by the initial menu.add() call. This is a limitation of the Titanium Android API. These 4 properties should not be assigned again afterwards. A newer version of underscore.js includes an
omit()
function which should make this trivial. We'll need to update underscore first.
The Ti.UI.Android.MenuItem parser now more efficiently processes its properties. It also uses the new Alloy.Android.menuItemCreateArgs array instead of re-creating the 4 property array every time that is required by the Titanium API for MenuItem.