[TIMOB-6204] Android: V8 - fireEvent does not work for Views
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2012-01-05T13:24:13.000+0000 |
Affected Version/s | Release 1.8.0.1 |
Fix Version/s | n/a |
Components | Android |
Labels | branch-v8, module_views, qe-testadded |
Reporter | Pedro Enrique |
Assignee | Hieu Pham |
Created | 2011-11-16T13:34:58.000+0000 |
Updated | 2013-11-07T05:47:05.000+0000 |
Description
Problem:
Setting a fireEvent() on any UI element does work with V8.Example:
var win = Ti.UI.createWindow();
var btn = Ti.UI.createButton({title:'here'});
win.addEventListener('background', function(){
win.backgroundColor = 'green';
});
btn.addEventListener('click', function(){
win.fireEvent('background');
});
win.add(btn);
win.open();
The pull request https://github.com/appcelerator/titanium_mobile/pull/710 should resolve this.
Cannot reproduce with latest master.
Tested with 1.8.0.1.v20111207090257 with v8/rhino on Xoom (3.2.1) Samsung Tab 10.1 (3.1)
Need to open to add label
label added
Open to add label
Anvil testcase PR https://github.com/appcelerator/titanium_mobile/pull/4887