[TIMOB-11281] iOS: Orientation - upside portrait mode is not recognized by application
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Closed |
Resolution | Cannot Reproduce |
Resolution Date | 2017-06-26T23:00:28.000+0000 |
Affected Version/s | Release 3.0.0 |
Fix Version/s | n/a |
Components | iOS |
Labels | qe-ios100112, qe-ios6 |
Reporter | Olga Romero |
Assignee | Eric Merriman |
Created | 2012-10-05T20:33:32.000+0000 |
Updated | 2017-06-26T23:00:28.000+0000 |
Description
Description:
An application does not recognize an upside portrait mode on rotation.
*This is not a regression, occurs on 2.1.3.GA and only on ios 6.0*
Test steps:
1) Create a new project and place the following in the app.js:
var btn = Ti.UI.createButton({
width: 70,
height: 70,
title: 'press me',
color: 'black'
});
_window.add(btn);
btn.addEventListener('click', function() {
var abtn = Ti.UI.createButton({
width: 40,
height: 40,
title: 'close',
color: 'black'
});
var wnd = Ti.UI.createWindow({
title : "Title Bar",
modal : true,
backgroundColor : "#FFF",
orientationModes : [Titanium.UI.PORTRAIT, Titanium.UI.UPSIDE_PORTRAIT, Titanium.UI.LANDSCAPE_LEFT, Titanium.UI.LANDSCAPE_RIGHT],
layout : "vertical"
});
var view = Ti.UI.createView({
backgroundColor : "#F00",
height : 200
});
var view2 = Ti.UI.createView({
backgroundColor : "#00F",
height : 216
});
var text = Ti.UI.createTextArea({
backgroundColor : "#0F0",
suppressReturn : false
});
view.add(text);
wnd.add(view);
wnd.add(view2);
view.add(abtn)
wnd.open();
abtn.addEventListener('click', function() {
wnd.close();
});
Ti.Gesture.addEventListener("orientationchange", function(event) {
view.height = 200;
view2.height = 216;
if(event.orientation === Ti.UI.LANDSCAPE_LEFT || event.orientation === Ti.UI.LANDSCAPE_RIGHT) {
view.height = 106;
view2.height = 162;
}
});
});
return _window;
2) Launch project
3)Click on "press me" button
4)Rotate device
Expected results: Application should recognize upside portrait mode, and 2 vies(blue ander red) should look the same as in portrait mode.
Actual result: After rotation from landscape to upside portrait views resize and stay in landscape. See attachments.
Attachments
File | Date | Size |
---|---|---|
expected landscape.png | 2012-10-05T20:33:32.000+0000 | 31127 |
expected portrait.png | 2012-10-05T20:33:32.000+0000 | 33216 |
upside down portrait_wrong.png | 2012-10-05T20:33:32.000+0000 | 30947 |
I am unable to reproduce this issue with the following environment; iPhone 7 (10.2) Studio 4.9.0.201705302345 Ti SDK 6.1.1.v20170623141152 Appc NPM 4.2.9 Appc CLI 6.2.1 Ti CLI 5.0.13 Alloy 1.9.11 Arrow 2.0.0 Xcode 8.2 (8C38) Node v4.8.2 Java 1.8.0_131