[TIMOB-16257] Ti.UI.ScrollView.setScrollingEnabled results in Java Exception
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2017-10-25T18:56:02.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Release 6.3.0 |
Components | Android |
Labels | android, scrollview, ui |
Reporter | Mauro Parra-Miranda |
Assignee | Joshua Quick |
Created | 2013-11-05T16:28:55.000+0000 |
Updated | 2017-10-26T22:15:29.000+0000 |
Description
Hi all, after upgrading to Alloy 1.2.2 Ti.UI.ScrollView.setScrollingEnabled results in and Uncaught Java Exception with no further details.
Also, the same result happens if statically setting the property.
<Alloy>
<ScrollView contentHeight="auto" contentWidth="auto" layout="vertical" height="Ti.UI.SIZE"></ScrollView>
</Alloy>
// Both of these return the same error
$.getView().setScrollingEnabled(true);
$.getView().scrollingEnabled = true;
Lee.
PR:- https://github.com/appcelerator/titanium_mobile/pull/5244
I'm able to reproduce this crash in a Classic App with the following lines of code in the "app.js" file
And with the "tiapp.xml" file set up to not run on the main UI thread. _(This crash will never happen if running from the main thread.)_
*Result:* The following exception gets outputted to the Android log...
*Cause:* There is message ID collision between the TiViewProxy and the ScrollViewProxy. The "MSG_FIRST_ID" should start from "TiViewProxy.MSG_LAST_ID", not "KrollProxy.MSG_LAST_ID"... https://github.com/appcelerator/titanium_mobile/blob/master/android/modules/ui/src/java/ti/modules/titanium/ui/ScrollViewProxy.java#L39
PR (master): https://github.com/appcelerator/titanium_mobile/pull/9550 PR (6.3.x): https://github.com/appcelerator/titanium_mobile/pull/9551
FR passed for both master & backport PR.
Master PR merged. Waiting for 6.3.0 PR to get merge enabled.
PR for backport merged.
Verified the fix in SDK 6.3.0.v20171026120401 & 7.0.0.v20171025141436. Closing. Studio Ver: 4.10.0.201709271713 OS Ver: 10.12.3 Xcode Ver: Xcode 8.3.3 Appc NPM: 4.2.10-2 Appc CLI: 6.3.0-master.15 Ti CLI Ver: 5.0.14 Alloy Ver: 1.10.6 Node Ver: 7.10.1 Java Ver: 1.8.0_101 Devices: ⇨ google Nexus 5 — Android 6.0.1 ⇨ google Pixel — Android 7.1.1