Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-512] iOS: setting orientation to landscape on main window in a tab = tabs cutoff

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionCannot Reproduce
Resolution Date2017-07-10T21:45:13.000+0000
Affected Version/sRelease 1.8.0.1, Release 3.0.0
Fix Version/sRelease 1.1.0
ComponentsiOS
Labelsn/a
ReporterNolan Wright
AssigneeEric Merriman
Created2011-04-15T02:30:41.000+0000
Updated2017-07-10T21:45:16.000+0000

Description

Set a main window in a tab group to LANDSCAPE_LEFT or RIGHT and the tabs get cut-off (4 tabs becomes 3)

Attachments

FileDateSize
incorrect tab change for unspecified orientation.png2011-12-09T17:02:11.000+000037782

Comments

  1. Blain Hamon 2011-04-15

    Could not recreate. Is there sample code?

  2. Dustin Hyde 2011-12-09

    Bug still valid. Verified on: SDK: 1.8.0.1.v20111209011840, 1.7.5 Studio: 1.0.7.201112080131 OS: OS X Lion Devices Affected: iPod 4.3, iPhone 5.0, iPhone Simulator 5.0 Devices Tested: iPod 4.3, iPhone 5.0, iPad 5.0, iPhone Simulator 5.0 When a window in a tab is set to LANDSCAPE (and the device is in landscape), if another tab is selected which contains a default window, the tabs get cut off on orientation change to portrait. Steps to Reproduce: 1. Run the default studio project code, with the first window set to LANDSCAPE_LEFT (full code below).
       // this sets the background color of the master UIView (when there are no windows/tab groups on it)
       Titanium.UI.setBackgroundColor('#000');
       
       // create tab group
       var tabGroup = Titanium.UI.createTabGroup();
       
       
       //
       // create base UI tab and root window
       //
       var win1 = Titanium.UI.createWindow({  
           title:'Tab 1',
           backgroundColor:'#fff',
           orientationModes:[Titanium.UI.LANDSCAPE_LEFT]
       });
       var tab1 = Titanium.UI.createTab({  
           icon:'KS_nav_views.png',
           title:'Tab 1',
           window:win1
       });
       
       var label1 = Titanium.UI.createLabel({
       	color:'#999',
       	text:'I am Window 1',
       	font:{fontSize:20,fontFamily:'Helvetica Neue'},
       	textAlign:'center',
       	width:'auto'
       });
       
       win1.add(label1);
       
       //
       // create controls tab and root window
       //
       var win2 = Titanium.UI.createWindow({  
           title:'Tab 2',
           backgroundColor:'#fff'
       });
       var tab2 = Titanium.UI.createTab({  
           icon:'KS_nav_ui.png',
           title:'Tab 2',
           window:win2
       });
       
       var label2 = Titanium.UI.createLabel({
       	color:'#999',
       	text:'I am Window 2',
       	font:{fontSize:20,fontFamily:'Helvetica Neue'},
       	textAlign:'center',
       	width:'auto'
       });
       
       win2.add(label2);
       
       
       
       //
       //  add tabs
       //
       tabGroup.addTab(tab1);  
       tabGroup.addTab(tab2);  
       
       
       // open tab group
       tabGroup.open();
       
    2. When the app first runs, tilt the device to landscape left. This orientation should match the first window. 3. Press the other tab. Expected Result: The app should change tabs and revert to portrait. The tabs should be completely visible. Actual Result: The app changes tabs and reverts to portrait, but the right-most tabs are cut off. This behavior is intermittent, and is most likely to occur on first run. Note: The iPad does not change to portrait on tab change.
  3. Stephen Tramer 2011-12-09

    Untagged from being a regression; OK to postpone.
  4. Junaid Younus 2012-08-13

    Able to reproduce this issue on a Samsung Galaxy S3 using TiSDK 2.2.0v20120810194112, TiStudio 2.1.1.201207271312.
  5. Lee Morris 2017-07-10

    I am unable to reproduce this issue with the following environment; iPhone 6 (10.0) Studio 4.9.0.201705302345 Ti SDK 6.1.1 GA Appc NPM 4.2.9 Appc CLI 6.2.2 Ti CLI 5.0.14 Alloy 1.9.11 Xcode 8.2 (8C38) Node v4.8.2 Java 1.8.0_131

JSON Source