Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-8379

Android: Orientation Landscape not working for tabs

    Details

    • Type: Bug
    • Status: Open
    • Priority: Low
    • Resolution: Unresolved
    • Affects Version/s: Release 3.1.0
    • Fix Version/s: None
    • Component/s: Android
    • Labels:
    • Environment:

      Titanium Studio,
      build: 1.0.8.201201262211,
      Mac os 10.7.2,
      Android 2.3 emulator.

      Description

      Problem Description

      I want to use some tabs with some content only in landscape mode. That doesn't work.

      Actual Results

      the window doesn't lock

      Expected results

      the tabs being locked at LAndscape

      Test Case

      var win = Titanium.UI.createWindow({
      	backgroundColor : '#fff',
      	title : 'X'
      });
      var win1 = Titanium.UI.createWindow({
      	backgroundColor : '#fff',
      	title : 'Y'
       
      });
       
      win.orientationModes = [
      //Titanium.UI.PORTRAIT,
      Titanium.UI.LANDSCAPE_LEFT];
       
      win1.orientationModes = [
      //Titanium.UI.PORTRAIT,
      Titanium.UI.LANDSCAPE_LEFT];
       
      // create tab group
      var tabGroup = Titanium.UI.createTabGroup();
       
      var tab1 = Titanium.UI.createTab({
      icon:'KS_nav_views.png',
      title:'FirstTab',
      window:win
       
      });
      var tab2 = Titanium.UI.createTab({
      icon:'KS_nav_views.png',
      title:'SecondTab',
      window:win1
      });
       
      // Create a Label.
      var aLabel1 = Ti.UI.createLabel({
      	text : 'TEST1',
      	color : 'red',
      	font : {fontSize:20},
      	height : 24,
      	width : 80,
      	top : 20,
      	left : 20,
      	textAlign : 'center'
      });
      // Create a Label.
      var aLabel2 = Ti.UI.createLabel({
      	text : 'TEST2',
      	color : 'red',
      	font : {fontSize:20},
      	height : 24,
      	width : 80,
      	top : 20,
      	left : 20,
      	textAlign : 'center'
      });
       
      // Add to the parent view.
      win.add(aLabel1);
      win1.add(aLabel2);
       
      tabGroup.addTab(tab1);
      tabGroup.addTab(tab2);
      tabGroup.open();
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                ybanev Yordan Banev
                Reporter:
                bartix99 bn
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:

                  Backbone Issue Sync

                  • Titanium SDK/CLI <> Titanium Mobile
                    Synced with:
                    TIMOB-12719
                    Sync status:
                    ERROR
                    Last received:
                    Last sent:

                    Git Source Code