<commit_before>////////////////////////////////////////////////////////////////////////////////
//
//  ADOBE SYSTEMS INCORPORATED
//  Copyright 2009 Adobe Systems Incorporated
//  All Rights Reserved.
//
//  NOTICE: Adobe permits you to use, modify, and distribute this file
//  in accordance with the terms of the license agreement accompanying it.
//
////////////////////////////////////////////////////////////////////////////////

package spark.effects
{
import mx.effects.IEffectInstance;

import spark.effects.supportClasses.AnimateTransformInstance;
    
/**
 * This class is a utility wrapper around the AnimateTransform effect, exposing the
 * properties that make sense for someone wishing to merely move a target object
 * in 3D. An important difference between this TransformMove
 * effect and the previous Move effect is that the x and y property specifications
 * for TransformMove specify not absolute values of the x/y point on the target
 * object, but rather the change in x/y that should occur to the center around
 * which the overall transform is occuring. So if, for example, the 
 * <code>autoCenterTransform</code> property is set, then the from/to/by values
 * in this effect will define how much to move the center of the target, not the 
 * (x,y) of the target.
 * 
 * <p>Like all AnimateTransform-based effects, this effect will only work on subclasses
 * of UIComponent and GraphicElement, as these effects depend on specific
 * transform functions in those classes. Also, all of these effects run one single
 * effect instance on any given target at a time, which means that they will
 * share the transform center set by any of the contributing effects.</p>
 */   
public class Move3D extends Move
{
    include "../core/Version.as";
    
    public function Move3D(target:Object=null)
    {
        super(target);
        affectLayout = false;
        applyLocalProjection = true;
        instanceClass = AnimateTransformInstance;
    }
        
    //----------------------------------
    //  zBy
    //----------------------------------

    [Inspectable(category="General", defaultValue="NaN")]

    /** 
     *  Number of pixels by which to modify the z of the component.
     *  Values may be negative.
     */
    public var zBy:Number;
    
    //----------------------------------
    //  zFrom
    //----------------------------------

    [Inspectable(category="General", defaultValue="NaN")]

    /** 
     *  Initial z.
     *  If omitted, Flex uses either the value in the start state,
     *  if the effect is playing in a state transition, or the current
     *  value in the target.
     */
    public var zFrom:Number;

    //----------------------------------
    //  zTo
    //----------------------------------

    [Inspectable(category="General", defaultValue="NaN")]

    /** 
     *  Final z
     *  If omitted, Flex uses either the value in the end state,
     *  if the effect is playing in a state transition, or the current
     *  value in the target.
     */
    public var zTo:Number;

    //--------------------------------------------------------------------------
    //
    //  Overridden methods
    //
    //--------------------------------------------------------------------------

    /**
     * @private
     */
   override protected function initInstance(instance:IEffectInstance):void
    {
        if(affectLayout)
        {
           addMotionPath("translationZ", zFrom, zTo, zBy);
        }
        else
        {
            addPostLayoutMotionPath("postLayoutTranslationX", xFrom, xTo, xBy);
        }
        super.initInstance(instance);
    }    
}
}<commit_msg>Transferred from the Adobe Open Source Subversion Repository<commit_after>////////////////////////////////////////////////////////////////////////////////
//
//  ADOBE SYSTEMS INCORPORATED
//  Copyright 2009 Adobe Systems Incorporated
//  All Rights Reserved.
//
//  NOTICE: Adobe permits you to use, modify, and distribute this file
//  in accordance with the terms of the license agreement accompanying it.
//
////////////////////////////////////////////////////////////////////////////////

package spark.effects
{
import mx.effects.IEffectInstance;

import spark.effects.supportClasses.AnimateTransformInstance;
    
/**
 * This class is a utility wrapper around the AnimateTransform effect, exposing the
 * properties that make sense for someone wishing to merely move a target object
 * in 3D. An important difference between this TransformMove
 * effect and the previous Move effect is that the x and y property specifications
 * for TransformMove specify not absolute values of the x/y point on the target
 * object, but rather the change in x/y that should occur to the center around
 * which the overall transform is occuring. So if, for example, the 
 * <code>autoCenterTransform</code> property is set, then the from/to/by values
 * in this effect will define how much to move the center of the target, not the 
 * (x,y) of the target.
 * 
 * <p>Like all AnimateTransform-based effects, this effect will only work on subclasses
 * of UIComponent and GraphicElement, as these effects depend on specific
 * transform functions in those classes. Also, all of these effects run one single
 * effect instance on any given target at a time, which means that they will
 * share the transform center set by any of the contributing effects.</p>
 */   
public class Move3D extends Move
{
    include "../core/Version.as";
    
    public function Move3D(target:Object=null)
    {
        super(target);
        affectLayout = false;
        applyLocalProjection = true;
        instanceClass = AnimateTransformInstance;
    }
        
    //----------------------------------
    //  zBy
    //----------------------------------

    [Inspectable(category="General", defaultValue="NaN")]

    /** 
     *  Number of pixels by which to modify the z of the component.
     *  Values may be negative.
     */
    public var zBy:Number;
    
    //----------------------------------
    //  zFrom
    //----------------------------------

    [Inspectable(category="General", defaultValue="NaN")]

    /** 
     *  Initial z.
     *  If omitted, Flex uses either the value in the start state,
     *  if the effect is playing in a state transition, or the current
     *  value in the target.
     */
    public var zFrom:Number;

    //----------------------------------
    //  zTo
    //----------------------------------

    [Inspectable(category="General", defaultValue="NaN")]

    /** 
     *  Final z
     *  If omitted, Flex uses either the value in the end state,
     *  if the effect is playing in a state transition, or the current
     *  value in the target.
     */
    public var zTo:Number;

    //--------------------------------------------------------------------------
    //
    //  Overridden methods
    //
    //--------------------------------------------------------------------------

    /**
     * @private
     */
   override protected function initInstance(instance:IEffectInstance):void
    {
        if(affectLayout)
        {
            addMotionPath("translationZ", zFrom, zTo, zBy);
        }
        else
        {
            addPostLayoutMotionPath("postLayoutTranslationZ", zFrom, zTo, zBy);
        }
        super.initInstance(instance);
    }    
}
}
{'fraction_non_alphanumeric': 0.20893489512394442, 'fraction_numerical': 0.0019068373740125306, 'mean_word_length': 1.608525754884547, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4328237', 'n_tokens_mistral': 1784, 'n_tokens_neox': 1705, 'n_words': 685}