Problem
When calling Ti.App.fireEvent() or Ti.App.addEventListener() from a webview, it crashes the app.
Sample Code to Reproduce Error:
app.js
var win = Ti.UI.createWindow();
var webView = Ti.UI.createWebView();
var html = '<html>' + '<head>' + '<meta name="viewport" content="width=device-width,user-scalable=yes,initial-scale=1">' + '<script src="global.js"></script>' + '</head>' + '<body>' + 'Hello world!' + '</body>' + '</html>';
webView.html = html;
win.add(webView);
win.open();
global.js
Titanium.App.addEventListener('scrollsContentToTop', function(e){});
Steps to Reproduce Error
1. Add the code above into respective js files
2. Run on android emulator 2.3.3 or 2.3.4 and any Titanium sdk
3. Watch for crash
I would expect the crash on a 2.3.x emulator (cf TIMOB-2682) but not on a device. However, The Environment field of this item says "Android 2.3.3 and 2.3.4 *device* and emulator.") Can the submitter please re-confirm that it happens on a real (non-emulator) device? If it does, please include logcat output and the make/model of the device. I don't personally have a 2.3 device, so if it turns out that indeed it's confirmed on the device, this item will need to be reassigned. I ran the test on 2.2, 3.1 and 4.1 devices just for a sanity check, and there were no crashes.
There is a reason why the ticket specifically says Android 2.3.3 and 2.3.4 device and emulator. You have to test on these versions to reproduce the problem.
I tested this on Titanium 2.1.0, 2.0.2 sdks with a android 2.3.6 and a 2.3.4 devices and could not reproduce the issue. Marking this as cannot reproduce.
Closing ticket as the issue cannot be reproduced and due to the above comments.