[AC-962] iOS can rotate once only
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | n/a |
| Status | Closed |
| Resolution | Cannot Reproduce |
| Resolution Date | 2014-08-26T06:30:11.000+0000 |
| Affected Version/s | n/a |
| Fix Version/s | n/a |
| Components | n/a |
| Labels | TCSupportTriage |
| Reporter | Wilton Kwok |
| Assignee | Mauro Parra-Miranda |
| Created | 2014-08-07T07:36:46.000+0000 |
| Updated | 2016-03-08T07:37:17.000+0000 |
Hello, We have tested this issue. It’s not a bug, orientation change works as expected when rotates the app to the SAME direction repeatedly. It may be a coding problem.
Testing Environment:
Titanium SDK: 3.3.0.GA, Titanium CLI: 3.3.0, IOS Simulator: 7.1, OS X Version: 10.9.3, Appcelerator Studio: 3.3.0Steps to Test:
1. Create an alloy project. 2. Paste this code in the controller and view folder. 3. Run this code with the testing environment. Test Codefunction onButtonClick(e) { var win = Alloy.createController('win1').getView(); $.nIndex.openWindow(win); } $.nIndex.open();<Alloy> <Window class="container"> <Label color="#fff">Win1</Label> </Window> </Alloy>Thanks.var args = arguments[0] || {}; var win = null; Ti.Gesture.addEventListener('orientationchange', changeOrientation); function changeOrientation(e) { if (Ti.Gesture.isPortrait()) { if (win != null) { win.close(); win = null; } } else if (Ti.Gesture.isLandscape()) { win = Ti.UI.createWindow({ width:Ti.UI.FILL, height:Ti.UI.FILL, fullscreen:true, orientationModes:[ Ti.UI.LANDSCAPE_LEFT, Ti.UI.LANDSCAPE_RIGHT], // navBarHidden:true, backgroundColor:'black', }); var label = Ti.UI.createLabel({ text:'Full screen', color:'yellow', }); win.add(label); win.open(); } }Provided a testcase that works fine. Please take a look and if you can reproduce the issue with the modifications, please let us know.