[TIMOB-20028] iOS: Layout fails on iOS8 with iOS9-only Picker height set
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2015-12-11T18:12:20.000+0000 |
Affected Version/s | Release 5.1.0 |
Fix Version/s | Release 5.2.0 |
Components | iOS |
Labels | picker, qe-5.2.0 |
Reporter | Fokke Zandbergen |
Assignee | Angel Petkov |
Created | 2015-11-21T10:49:02.000+0000 |
Updated | 2016-01-22T00:42:15.000+0000 |
Description
Since iOS 9 it is possible to set a picker's height and we support that in Titanium 5.1.0.
However, on iOS 8 the layout seems to use the set height, resulting in the standard-height picker to overflow. See screenshots.
On iOS 8 we should use the standard-height to do the layout. This should also be reflected when you get the height via the
size
and rect
properties.
Found by [~ewieber] and demonstrated in the Ti 5.1.0 sample app
https://github.com/appcelerator-developer-relations/appc-sample-ti510/issues/3
Attachments
File | Date | Size |
---|---|---|
Simulator Screen Shot 11 Dec 2015 09.39.49.png | 2015-12-11T08:45:21.000+0000 | 113889 |
Simulator Screen Shot 21 Nov 2015 11.40.07.png | 2015-11-21T10:48:58.000+0000 | 124565 |
Simulator Screen Shot 21 Nov 2015 11.41.20.png | 2015-11-21T10:48:58.000+0000 | 83503 |
Hey [~apetkov], so on iOS 8 the picker will now appear full height and not overflow? I think that's fine.
The picker is full height on that image , the problem is that prior to iOS 9 it's height cant be set. So it will always be the same size, thats why it appears to be overflowing as it's overlapping the labels.
OK, so with this fix if I set a height on the picker it will be ignored on iOS 8 and the picker will display in standard height, without overflowing the frame? That is, assuming the layout is vertical of course. If it's absolute and you position the view below it using a
top
that expects the picker to be the height you've set it to be then it will still appear over the picker.Looks great now (see attached screenshot)
Great, thanks Fokke!
Verifed as fixed, logged height when app builts to 8.4 is
216
, scale of picker on iOS9 can be changed appropriately. Tested on: iPhone 6s Plus Device (9.2) & iPhone 6 Plus Device (8.4) Mac OSX El Capitan 10.11 (15A284) Ti SDK: 5.2.0.v20160114021251 Appc NPM: 4.2.3-1 App CLI: 5.2.0-231 Xcode 7.2 Node v4.2.3 *Closing Ticket.*