Comunidad de diseño web y desarrollo en internet online

Ejecutar transiciones en TabNavigator

Citar            
MensajeEscrito el 30 Jul 2009 03:06 am
Que tal?, alguno de ustedes sabe como puedo ejecutar transiciones y efectos cuando paso de un tab de un TabNavigator a otro tab, por que se como hacerlo desde estados pero no se me prende el foco sobre como hacerlo entre estos que menciono..

de antemano gracias..

Por hectberlag

30 de clabLevel



 

chrome
Citar            
MensajeEscrito el 30 Jul 2009 04:51 am
muy facil amigo
un ejemplo

Código :

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" verticalAlign="top"
    horizontalAlign="center" backgroundGradientColors="[0x000000,0x323232]" paddingTop="0" viewSourceURL="srcview/index.html">
    
<mx:Move id="hideEffect"
          xTo="-950"/>
   <mx:Move id="showEffect"
          xFrom="950"/>
    <mx:Panel title="TabNavigator Container" layout="vertical" color="0xffffff" borderAlpha="0.15" height="240"
         paddingTop="10" paddingRight="10" paddingBottom="10" paddingLeft="10" horizontalAlign="center">
         
         <mx:Label width="100%" color="0x323232" fontWeight="bold"
            text="Select the tabs to change the panel."/>

        <mx:TabNavigator id="tn"  width="100%" height="100%" color="0x323232" >
            <!-- Define each panel using a VBox container. -->

            <mx:VBox label="Panel 1" hideEffect="{hideEffect}"
                  showEffect="{showEffect}" >
                <mx:Label text="TabNavigator container panel 1"/>
            </mx:VBox>

            <mx:VBox label="Panel 2" hideEffect="{hideEffect}"
                  showEffect="{showEffect}">
                <mx:Label text="TabNavigator container panel 2"/>
            </mx:VBox>

            <mx:VBox label="Panel 3" hideEffect="{hideEffect}"
                  showEffect="{showEffect}" >
                <mx:Label text="TabNavigator container panel 3"/>
            </mx:VBox>
        </mx:TabNavigator>

        <mx:Label width="100%" color="0x323232"
            text="Programmatically select the panel using a Button control."/>

        <mx:HBox>
            <mx:Button label="Select Tab 1" click="tn.selectedIndex=0" color="0x545454" />
            <mx:Button label="Select Tab 2" click="tn.selectedIndex=1" color="0x545454" />
            <mx:Button label="Select Tab 3" click="tn.selectedIndex=2" color="0x545454" />
        </mx:HBox>
        
    </mx:Panel>
</mx:Application>

luego cambia el valor de show efect ya que estoy moviendo a 950 eso depender de tu tamaño de tu aplicacion
ya que se veria mal entiendes.. AHORA DIME ERES MI IDOLO JAJAJAJ BROMA

Por xcom

Claber

530 de clabLevel



 

firefox
Citar            
MensajeEscrito el 30 Jul 2009 02:39 pm
Gracias amigo voy a probar

Por hectberlag

30 de clabLevel



 

firefox

 

Cristalab BabyBlue v4 + V4 © 2011 Cristalab
Powered by ClabEngines v4, HTML5, love and ponies.