Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-15778] iOS: setting orientationModes on a Ti.UI.TabGroup does not work

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionInvalid
Resolution Date2013-11-26T00:22:54.000+0000
Affected Version/sRelease 3.2.0
Fix Version/sn/a
ComponentsiOS
Labelsqe-3.2.0
ReporterPriya Agarwal
AssigneeIngo Muschenetz
Created2013-11-21T10:50:18.000+0000
Updated2013-12-06T09:59:33.000+0000

Description

var modes = [Ti.UI.LANDSCAPE_LEFT, Ti.UI.LANDSCAPE_RIGHT];
var modesEnabled = true;
 
var tabGroup = Ti.UI.createTabGroup({
  orientationModes: modes
});
 
var tabWindow = Ti.UI.createWindow();
tabGroup.addTab(Ti.UI.createTab({window: tabWindow, title: 'Lonely tab'}));
 
var toggleModesButton = Ti.UI.createButton({
  title: 'Toggle orientationModes'
});
toggleModesButton.addEventListener('click', function() {
  tabGroup.orientationModes = modesEnabled ? [ ] : modes;
  modesEnabled = !modesEnabled;
});
tabWindow.add(toggleModesButton);
 
tabGroup.open();
Steps to reproduce: 1.Copy paste the code in app.js. 2.Run the app. 3.Click "Toggle orientationModes" buttonTest steps Expected result 2. The window should open in landscape mode(supporting both landscape left and landscape right). 3. Now the window should support only portrait mode. Actual result 3. Clicking the 'toggle orientation mode' does not make the app support Portrait orientation mode.

Comments

  1. Sabil Rahim 2013-11-26

    This is a invalid ticket, Since 3.1.3.GA (window's refactor). Once a window/NavigationGroup/TabGroup is opened you cannot change its orientationMode.
  2. Priya Agarwal 2013-12-06

    Closing as per above comments.

JSON Source