[TIMOB-19908] iOS: Ti.UI.ScrollableView was not shown
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2016-04-04T13:39:44.000+0000 |
Affected Version/s | Release 5.1.0 |
Fix Version/s | Release 5.4.0 |
Components | iOS |
Labels | AL-5.4.0, autolayout, notable, qe-5.4.0 |
Reporter | Kosuke Isobe |
Assignee | Chee Kiat Ng |
Created | 2015-11-10T23:50:43.000+0000 |
Updated | 2016-07-07T19:41:54.000+0000 |
Description
In use-autolayout enabled and specification the width/height properties.
Test case.
*tiapp.xml*
<ios>
<use-autolayout>true</use-autolayout>
</ios>
*app.js*
var win = Ti.UI.createWindow(),
view0 = Ti.UI.createView({
backgroundColor: 'red'
}),
view1 = Ti.UI.createView({
backgroundColor: 'green'
}),
view2 = Ti.UI.createView({
backgroundColor: 'blue'
}),
scrollableview = Ti.UI.createScrollableView({
width: 200, // not the Ti.UI.FILL or SIZE
height: 200, // not the Ti.UI.FILL or SIZE
views: [
view0,
view1,
view2
]
});
win.add(scrollableview);
win.open();
Fixed in this PR https://github.com/appcelerator/titanium_mobile/pull/7553
APPROVED. PR Merged.
I am still able to reproduce the error with the latest 5.2.X SDK. Tested the above test case against several SDKs and found the following: 5.1.1.GA SDK: App launches & Black Screen, no Scrollable View. 5.1.2.GA SDK: App hangs on splash screen. 5.2.0.v20160114021251 SDK: App launches & White Screen, no Scrollable View. In all cases, removing
<use-autolayout>true</use-autolayout>
from the tiapp.xml fixes the issue and the scrollable view is shown, setting autolayout tofalse
in all cases also fixes the issue. iPhone 6s Plus Device (9.2) Mac OSX El Capitan 10.11 (15A284) Ti SDK: 5.2.0.v20160114021251 , 5.1.1.GA , 5.1.2.GA Appc NPM: 4.2.3-1 , 4.2.2 App CLI: 5.2.0-228 , 5.1.0 Xcode 7.2 Node v4.2.3 *Reopening Ticket.*PR: https://github.com/appcelerator/titanium_mobile/pull/7809
PR: https://github.com/appcelerator/titanium_mobile/pull/7896
To test
IN these 2 scenarios, this should work perfectly a) run-on-main-thread enabled, auto layout enabled b) run-on-main-thread disabled, auto layout disabled [~bimmel] To consider for 5.4.0 release notes, we may need to inform developers, if they wish to use auto layout, run-on-main-thread MUST be enabled.Thanks Hans!!!! So I'm assuming that with everything disabled, these still function as per normal? I think i just fixed those 2 issues. checking again and will update PR.
Here's a better PR: https://github.com/appcelerator/titanium_mobile/pull/7914
Verified as fixed. Tested on: iPhone 5s (9.2) iOS Simulator (9.3) Mac OSX El Capitan 10.11.5 Studio: 4.7.0.201607070843 Ti SDK: 5.4.0.v20160705213725 Appc NPM: 4.2.8-1 Appc CLI: 5.4.0-26 Xcode 7.3.1 Node v4.4.4 * Closing Ticket*