Finds animation declarations and puts them into the output map.
434456
function(input, output) {
		rxAnimation.lastIndex = 0;

		var animation;
		var rawKeyframes;
		var keyframe;
		var curAnimation;

		while((animation = rxAnimation.exec(input)) !== null) {
			//Grab the keyframes inside this animation.
			rxKeyframes.lastIndex = rxAnimation.lastIndex;
			rawKeyframes = rxKeyframes.exec(input);

			//Grab the single keyframes with their CSS properties.
			rxSingleKeyframe.lastIndex = 0;

			//Save the animation in an object using it's name as key.
			curAnimation = output[animation[1]] = {};

			while((keyframe = rxSingleKeyframe.exec(rawKeyframes[1])) !== null) {
				//Put all keyframes inside the animation using the keyframe (like botttom-top, or 100) as key
				//and the properties as value (just the raw string, newline stripped).
				curAnimation[keyframe[1]] = keyframe[2].replace(/[\n\r\t]/g, '');
			}
		}
	}
988522
function createAnimationObject(categoryName, fileName){
    var animation,
        inputFilepath = config.src + categoryName + '/' + fileName + '.css',
        inputPlainFilepath = config.unprefixedSrc + categoryName + '/' + fileName + '.css',
        outpuFilepath = config.dest + categoryName + '/' + 'db_'+ fileName + '.json',
        currentFileSource,
        currentFilePlainSource,
        metadataObject;

    // read the file
    currentFileSource = grunt.file.read(inputFilepath);
    currentFilePlainSource = grunt.file.read(inputPlainFilepath);

    // extract relevant data
    animation = parseString(currentFileSource);

    // TODO: quitar los comentarios antes de guardarlo
    if(animation.length > 0){
      animation = animation[0];
      animation.cssCode = new CleanCSS({
        noAdvanced:false,
        aggressiveMerging:false,
        keepBreaks:true
      }).minify(currentFileSource);

      animation.plainCssCode = new CleanCSS({
        noAdvanced:false,
        aggressiveMerging:false,
        keepBreaks:true
      }).minify(currentFilePlainSource);
      animation.cssCode = beautify_css(animation.cssCode, { indent_size: 2 });
      animation.plainCssCode = beautify_css(animation.plainCssCode, { indent_size: 2 });
    }

    // write destiny
    grunt.file.write(outpuFilepath, JSON.stringify(animation, null, 4));
  }
88848
function(input, output) {
		var match;
		var selector;

		rxAttributeSetter.lastIndex = 0;

		while((match = rxAttributeSetter.exec(input)) !== null) {
			//Extract the selector of the block we found the animation in.
			selector = extractSelector(input, rxAttributeSetter.lastIndex);

			//Associate this selector with the attribute name and value.
			output.push([selector, match[1], match[2]]);
		}
	}
911663
private void startAnimation() {
        ValueAnimator animator = ValueAnimator.ofFloat(1.0f);
        ArrayList<NameValuesHolder> nameValueList =
                (ArrayList<NameValuesHolder>) mPendingAnimations.clone();
        mPendingAnimations.clear();
        int propertyMask = 0;
        int propertyCount = nameValueList.size();
        for (int i = 0; i < propertyCount; ++i) {
            NameValuesHolder nameValuesHolder = nameValueList.get(i);
            propertyMask |= nameValuesHolder.mNameConstant;
        }
        mAnimatorMap.put(animator, new PropertyBundle(propertyMask, nameValueList));
        animator.addUpdateListener(mAnimatorEventListener);
        animator.addListener(mAnimatorEventListener);
        if (mStartDelaySet) {
            animator.setStartDelay(mStartDelay);
        }
        if (mDurationSet) {
            animator.setDuration(mDuration);
        }
        if (mInterpolatorSet) {
            animator.setInterpolator(mInterpolator);
        }
        animator.start();
    }
807913
private void initHideAnimation(TypedArray attrs) {
		int index = R.styleable.ActionButton_hide_animation;
		if (attrs.hasValue(index)) {
			int animResId = attrs.getResourceId(index, Animations.NONE.animResId);
			hideAnimation = Animations.load(getContext(), animResId);
			LOGGER.trace("Initialized Action Button hide animation");
		}
	}
1362553
def make_map(declarations):
    """"""
    mapper = routes.Mapper()
    for route, methods in ROUTE_LIST:
        allowed_methods = []
        for method, func in methods.items():
            mapper.connect(route, action=func,
                           conditions=dict(method=[method]))
            allowed_methods.append(method)
        allowed_methods = ', '.join(allowed_methods)
        mapper.connect(route, action=handle_not_allowed,
                       _methods=allowed_methods)
    return mapper
1128512
private void autoDetectAnimatedGroups()
	{
		animatedShapes = model.getAnimatedShapes();
		staticShapes = model.getShapeNames().stream().filter(s -> !animatedShapes.contains(s)).collect(Collectors.toSet());

		//Debug: all animated
		//		animatedShapes.addAll(staticShapes);
		//		staticShapes.clear();
	}
480436
function Animation(envMap) {
  var rangeX = 300;
  var rangeY = 200;
  var prefabCount = 6;
  var size = rangeY / prefabCount;

  //var prefabGeometry = new THREE.TorusKnotGeometry(size * 0.25, 2.0);
  var prefabGeometry = new THREE.TorusGeometry(size * 0.25, 4.0, 32, 16);
  var geometry = new BAS.PrefabBufferGeometry(prefabGeometry, prefabCount);

  var i;
  var prefabDataArray = [];

  var aDelayDuration = geometry.createAttribute('aDelayDuration', 2);
  var duration = 1.0;
  var maxPrefabDelay = 0.5;

  this.totalDuration = duration + maxPrefabDelay;

  for (i = 0; i < prefabCount; i++) {
    var delay = THREE.Math.mapLinear(i, 0, prefabCount, 0.0, maxPrefabDelay);

    geometry.setPrefabData(aDelayDuration, i, [delay, duration]);
  }

  var aStartPosition = geometry.createAttribute('aStartPosition', 3);
  var aEndPosition = geometry.createAttribute('aEndPosition', 3);
  var startPosition = new THREE.Vector3();
  var endPosition = new THREE.Vector3();

  for (i = 0; i < prefabCount; i++) {
    startPosition.x = -rangeX * 0.5;
    startPosition.y = THREE.Math.mapLinear(i, 0, prefabCount, -rangeY * 0.5, rangeY * 0.5) + size * 0.5;
    startPosition.z = 0;

    endPosition.x = rangeX * 0.5;
    endPosition.y = startPosition.y;
    endPosition.z = 0;

    geometry.setPrefabData(aStartPosition, i, startPosition.toArray(prefabDataArray));
    geometry.setPrefabData(aEndPosition, i, endPosition.toArray(prefabDataArray));
  }

  var aAxisAngle = geometry.createAttribute('aAxisAngle', 4);
  var axis = new THREE.Vector3();
  var angle;

  for (i = 0; i < prefabCount; i++) {
    axis.x = THREE.Math.randFloatSpread(2);
    axis.y = THREE.Math.randFloatSpread(2);
    axis.z = THREE.Math.randFloatSpread(2);
    axis.normalize();
    angle = Math.PI * 2;

    axis.toArray(prefabDataArray);
    prefabDataArray[3] = angle;

    geometry.setPrefabData(aAxisAngle, i, axis.toArray(prefabDataArray));
  }

  var material = new BAS.PhongAnimationMaterial({
    transparent: true,
    uniforms: {
      uTime: {value: 0},
      uBezierCurve: {value: new THREE.Vector4(.42,0,.58,1)},
      uMap2: {value: null}
    },
    uniformValues: {
      map: new THREE.TextureLoader().load('../_tex/UV_Grid.jpg'),
      envMap: envMap,
      //combine: THREE.MultiplyOperation,
      reflectivity: 0.75,
      //refractionRatio: 0.98
    },
    // functions for the vertex shader (cannot be used in the fragment shader)
    vertexFunctions: [
      BAS.ShaderChunk['ease_bezier'],
      BAS.ShaderChunk['quaternion_rotation']
    ],
    // parameters for the vertex shader
    vertexParameters: [
      'uniform float uTime;',
      'uniform vec4 uBezierCurve;',
      'attribute vec2 aDelayDuration;',
      'attribute vec3 aStartPosition;',
      'attribute vec3 aEndPosition;',
      'attribute vec4 aAxisAngle;'
    ],
    // varying parameters get injected into both the vertex and the fragment shader
    varyingParameters: [
      'varying float vAlpha;',
      'varying vec3 vEmissive;',
      'varying vec3 vSpecular;',
      'varying float vShininess;',
      'varying float vProgress;'
    ],
    // this chunk gets injected at the top of main() of the vertex shader
    vertexInit: [
      'float tProgress = clamp(uTime - aDelayDuration.x, 0.0, aDelayDuration.y) / aDelayDuration.y;',
      'tProgress = easeBezier(tProgress, uBezierCurve);',
      'vProgress = tProgress;',

      'vec4 tQuat = quatFromAxisAngle(aAxisAngle.xyz, aAxisAngle.w * tProgress);'
    ],
    // this chunk gets injected after <beginnormal_vertex> (before any other normal calculations)
    // objectNormal (transformed normal) is used throughout the vertex shader
    vertexNormal: [
      'objectNormal = rotateVector(tQuat, objectNormal);'
    ],
    // this chunk gets injected after <begin_vertex> (before any other normal calculations)
    // transformed (transformed position) is used throughout the vertex shader
    vertexPosition: [
      'transformed = rotateVector(tQuat, transformed);',
      'transformed += mix(aStartPosition, aEndPosition, tProgress);'
    ],
    // this chunk gets injected after vertexPosition
    vertexColor: [
      // these don't make any sense - it's just to test if it works
      'vAlpha = abs(transformed.x) / 150.0 * 0.9 + 0.1;', // based on rangeX = 300
      'vEmissive = abs(normalize(transformed));',
      'vSpecular = abs(normalize(transformed));',
      'vShininess = abs(transformed.z * 100.0);'
    ],
    // functions for the fragment shader (cannot be used in vertex shader)
    fragmentFunctions: [

    ],
    // parameters for the fragment shader
    fragmentParameters: [
      'uniform sampler2D uMap2;'
    ],
    // this chunk overrides <map_fragment>
    // see https://github.com/mrdoob/three.js/blob/master/src/renderers/shaders/ShaderChunk/map_fragment.glsl
    fragmentMap: [
      'vec4 texelColor1 = texture2D(map, vUv);',
      'vec4 texelColor2 = texture2D(uMap2, vUv);',
      'vec4 texelColor = mapTexelToLinear(mix(texelColor1, texelColor2, vProgress));',
      'diffuseColor *= texelColor;'
    ],
    // this chunk gets injected after 'diffuseColor' is defined
    // changes to diffuse color (outside of vertex colors) and alpha should go here
    // diffuseColor is used throughout the fragment shader
    fragmentDiffuse: [
      'diffuseColor.a *= vAlpha;'
    ],
    // this chunk gets injected before <emissivemap_fragment>
    // totalEmissiveRadiance is modulated by the emissive map color
    fragmentEmissive: [
      'totalEmissiveRadiance = vEmissive;' // default emissive = (0, 0, 0)
    ],
    // this chunk gets injected after <fragmentSpecular>
    fragmentSpecular: [
      'material.specularStrength = 0.25;',
      'material.specularShininess = vShininess;',
      'material.specularColor = vSpecular;'
    ]
  });

  // for some reason setting the value inside the constructor does not work :'(
  material.uniforms.uMap2.value = new THREE.TextureLoader().load('../_tex/brick_diffuse.jpg');

  geometry.computeVertexNormals();
  geometry.bufferUvs();

  THREE.Mesh.call(this, geometry, material);

  this.frustumCulled = false;
}
840433
function forFade(props) {
  const { layout, position, scene } = props;

  if (!layout.isMeasured) {
    return forInitial(props);
  }
  const interpolate = getSceneIndicesForInterpolationInputRange(props);

  if (!interpolate) return { opacity: 0 };

  const { first, last } = interpolate;
  const index = scene.index;
  const opacity = position.interpolate({
    inputRange: [first, index, last],
    outputRange: [0, 1, 1],
  });

  return {
    opacity,
  };
}
747118
function (target, options) {
        options = options || {};
        var animator = new Animator(
            target,
            options.loop,
            options.getter,
            options.setter,
            options.interpolater
        );
        animator.animation = this;
        return animator;
    }
205021
function () {
    var config = this.config;
    var data = this.data;
    var el = this.el;
    var key;
    var from;
    var to;

    // Parse coordinates.
    from = data.from !== ''
      ? utils.coordinates.parse(data.from)  // If data.from defined, use that.
      : getComponentProperty(el, data.property);  // If data.from not defined, get on the fly.
    to = utils.coordinates.parse(data.to);

    if (data.property === PROP_ROTATION) {
      toRadians(from);
      toRadians(to);
    }

    // Set to and from.
    this.targetsArray.length = 0;
    this.targetsArray.push(from);
    config.targets = this.targetsArray;
    for (key in to) { config[key] = to[key]; }

    // If animating object3D transformation, run more optimized updater.
    if (data.property === PROP_POSITION || data.property === PROP_ROTATION ||
        data.property === PROP_SCALE) {
      config.update = (function () {
        var lastValue = {};
        return function (anim) {
          var value = anim.animatables[0].target;

          if (data.property === PROP_SCALE) {
            value.x = Math.max(0.0001, value.x);
            value.y = Math.max(0.0001, value.y);
            value.z = Math.max(0.0001, value.z);
          }

          // For animation timeline.
          if (value.x === lastValue.x &&
              value.y === lastValue.y &&
              value.z === lastValue.z) { return; }

          lastValue.x = value.x;
          lastValue.y = value.y;
          lastValue.z = value.z;

          el.object3D[data.property].set(value.x, value.y, value.z);
        };
      })();
      return;
    }

    // Animating some vector.
    config.update = (function () {
      var lastValue = {};
      return function (anim) {
        var value = anim.animatables[0].target;

        // Animate rotation through radians.
        // For animation timeline.
        if (value.x === lastValue.x &&
            value.y === lastValue.y &&
            value.z === lastValue.z) { return; }
        lastValue.x = value.x;
        lastValue.y = value.y;
        lastValue.z = value.z;
        setComponentProperty(el, data.property, value);
      };
    })();
  }
789848
private void completeAnimation() {
		mScroller.abortAnimation();
		final int finalX = mScroller.getFinalX();
		setOffsetPixels(finalX);
		setDrawerState(finalX == 0 ? STATE_CLOSED : STATE_OPEN);
		stopLayerTranslation();
	}
1298800
private void animateExpand() {
        mCloseBtn.setVisibility(View.VISIBLE);
        mMidContainer.setVisibility(View.VISIBLE);
        mRightContainer.setVisibility(View.VISIBLE);
        mLeftContainer.setVisibility(View.VISIBLE);

        setButtonsVisibleForPreHC();

        ANIMATION_COUNTER = 0;

        ViewPropertyAnimator.animate(mMidContainer).setDuration(ANIMATION_DURATION).translationYBy(-TRANSLATION_Y).setInterpolator(overshoot).setListener(ON_EXPAND_COLLAPSE_LISTENER);
        ViewPropertyAnimator.animate(mRightContainer).setDuration(ANIMATION_DURATION).translationYBy(-TRANSLATION_Y).translationXBy(TRANSLATION_X).setInterpolator(overshoot).setListener(ON_EXPAND_COLLAPSE_LISTENER);
        ViewPropertyAnimator.animate(mLeftContainer).setDuration(ANIMATION_DURATION).translationYBy(-TRANSLATION_Y).translationXBy(-TRANSLATION_X).setInterpolator(overshoot).setListener(ON_EXPAND_COLLAPSE_LISTENER);
    }
1228957
static int getAnimationResource(int gravity, boolean isInAnimation) {
    if ((gravity & Gravity.TOP) == Gravity.TOP) {
      return isInAnimation ? R.anim.slide_in_top : R.anim.slide_out_top;
    }
    if ((gravity & Gravity.BOTTOM) == Gravity.BOTTOM) {
      return isInAnimation ? R.anim.slide_in_bottom : R.anim.slide_out_bottom;
    }
    if ((gravity & Gravity.CENTER) == Gravity.CENTER) {
      return isInAnimation ? R.anim.fade_in_center : R.anim.fade_out_center;
    }
    return INVALID;
  }
752130
function declarations() {
    var decls = [];

    if (!open()) return error("missing '{'");
    comments(decls);

    // declarations
    var decl;
    while (decl = declaration()) {
      if (decl !== false) {
        decls.push(decl);
        comments(decls);
      }
    }

    if (!close()) return error("missing '}'");
    return decls;
  }
23670
private void setUpAnimations() {
        slideUp = AnimationUtils.loadAnimation(this,
                R.anim.slide_up);
        slideDown = AnimationUtils.loadAnimation(this,
                R.anim.slide_down);
    }
684155
function (animation) {
            var chart = this,
              axes = chart.axes,
              series = chart.series,
              pointer = chart.pointer,
              legend = chart.legend,
              redrawLegend = chart.isDirtyLegend,
              hasStackedSeries,
              hasDirtyStacks,
              hasCartesianSeries = chart.hasCartesianSeries,
              isDirtyBox = chart.isDirtyBox, // todo: check if it has actually changed?
              seriesLength = series.length,
              i = seriesLength,
              serie,
              renderer = chart.renderer,
              isHiddenChart = renderer.isHidden(),
              afterRedraw = [];

            setAnimation(animation, chart);

            if (isHiddenChart) {
                chart.cloneRenderTo();
            }

            // Adjust title layout (reflow multiline text)
            chart.layOutTitles();

            // link stacked series
            while (i--) {
                serie = series[i];

                if (serie.options.stacking) {
                    hasStackedSeries = true;

                    if (serie.isDirty) {
                        hasDirtyStacks = true;
                        break;
                    }
                }
            }
            if (hasDirtyStacks) { // mark others as dirty
                i = seriesLength;
                while (i--) {
                    serie = series[i];
                    if (serie.options.stacking) {
                        serie.isDirty = true;
                    }
                }
            }

            // handle updated data in the series
            each(series, function (serie) {
                if (serie.isDirty) { // prepare the data so axis can read it
                    if (serie.options.legendType === 'point') {
                        redrawLegend = true;
                    }
                }
            });

            // handle added or removed series
            if (redrawLegend && legend.options.enabled) { // series or pie points are added or removed
                // draw legend graphics
                legend.render();

                chart.isDirtyLegend = false;
            }

            // reset stacks
            if (hasStackedSeries) {
                chart.getStacks();
            }


            if (hasCartesianSeries) {
                if (!chart.isResizing) {

                    // reset maxTicks
                    chart.maxTicks = null;

                    // set axes scales
                    each(axes, function (axis) {
                        axis.setScale();
                    });
                }

                chart.adjustTickAmounts();
            }

            chart.getMargins(); // #3098

            if (hasCartesianSeries) {
                // If one axis is dirty, all axes must be redrawn (#792, #2169)
                each(axes, function (axis) {
                    if (axis.isDirty) {
                        isDirtyBox = true;
                    }
                });

                // redraw axes
                each(axes, function (axis) {

                    // Fire 'afterSetExtremes' only if extremes are set
                    if (axis.isDirtyExtremes) { // #821
                        axis.isDirtyExtremes = false;
                        afterRedraw.push(function () { // prevent a recursive call to chart.redraw() (#1119)
                            fireEvent(axis, 'afterSetExtremes', extend(axis.eventArgs, axis.getExtremes())); // #747, #751
                            delete axis.eventArgs;
                        });
                    }

                    if (isDirtyBox || hasStackedSeries) {
                        axis.redraw();
                    }
                });
            }

            // the plot areas size has changed
            if (isDirtyBox) {
                chart.drawChartBox();
            }


            // redraw affected series
            each(series, function (serie) {
                if (serie.isDirty && serie.visible &&
                  (!serie.isCartesian || serie.xAxis)) { // issue #153
                    serie.redraw();
                }
            });

            // move tooltip or reset
            if (pointer) {
                pointer.reset(true);
            }

            // redraw if canvas
            renderer.draw();

            // fire the event
            fireEvent(chart, 'redraw'); // jQuery breaks this when calling it from addEvent. Overwrites chart.redraw

            if (isHiddenChart) {
                chart.cloneRenderTo(true);
            }

            // Fire callbacks that are put on hold until after the redraw
            each(afterRedraw, function (callback) {
                callback.call();
            });
        }