Using a custom easing function : Easing « Effects « Flex

Home
Flex
1.Chart
2.Components
3.Container
4.Data Model
5.Development
6.Effects
7.Event
8.Graphics
9.Grid
10.Style
Flex » Effects » EasingScreenshots 
Using a custom easing function
Using a custom easing function
         
<?xml version="1.0"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
    backgroundColor="white">
    <mx:Script>
        public function myEasing(t:Number, b:Number, c:Number,d:Number):Number 
            t/=d; 
            return b+c*(t)
        }
    </mx:Script>
    <mx:Move id="myEffect" xBy="300" easingFunction="{myEasing}" />
    <mx:Button label="Make me move" mouseDownEffect="{myEffect}" />
</mx:Application>

   
    
    
    
    
    
    
    
    
  
Related examples in the same category
1.Creating a custom easing functionCreating a custom easing function
2.Resize with easing functionResize with easing function
3.Easing DemoEasing Demo
4.Bounce and Elastic easing classesBounce and Elastic easing classes
ww_w___._ja___v___a__2_s___.c_om__ | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.