[TIMOB-10344] Android: Implement applyProperties({}) method on Ti.UI objects to take a list of json properties as is done at create time.
GitHub Issue | n/a |
---|---|
Type | New Feature |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2012-08-15T16:44:45.000+0000 |
Affected Version/s | Release 3.0.0 |
Fix Version/s | Sprint 2012-17 API, Release 3.0.0 |
Components | Android |
Labels | api, module_button, qe-review, qe-testadded |
Reporter | Russell McMahon |
Assignee | Ping Wang |
Created | 2012-08-08T11:44:01.000+0000 |
Updated | 2013-12-10T06:01:21.000+0000 |
Description
var win = Titanium.UI.createWindow({backgroundColor:'white'});
win.open();
var btn = Ti.UI.createButton({left:10, top:10, width:100, height:40, title:'Tap Me!'});
btn.addEventListener('click',function(e){
btn.applyProperties({width:200,height:100,title:'I Was Tapped!'});
});
win.add(btn);
Moving to next Sprint
Fixed by https://github.com/appcelerator/titanium_mobile/pull/2749 on master
Environment used for verification - Tested with Titanium SDK: 2.2.0.v20120815194913 Tested with Titanium Studio: 2.1.1.201207271312 Device - Samsung GALAXY Note Android 2.3.6 Machine OS - MAC 10.7.3
Anvil testcase PR https://github.com/appcelerator/titanium_mobile/pull/5047