function AdfDvtAnimator() {
}
AdfObject.createSubclass(AdfDvtAnimator);
AdfDvtAnimator.$getAnimator$ = function $AdfDvtAnimator$$getAnimator$$() {
  if (!AdfDvtAnimator.$_animator$) {
    var $animator_platform$$23$$ = AdfAgent.AGENT.getPlatform(), $version$$14$$ = AdfAgent.AGENT.getVersion(), $animator_platform$$23$$ = $animator_platform$$23$$ == AdfAgent.WEBKIT_PLATFORM ? new $AdfDvtWebkitAnimator$$ : $animator_platform$$23$$ == AdfAgent.GECKO_PLATFORM && 2 <= $version$$14$$ ? new $AdfDvtGeckoAnimator$$ : $animator_platform$$23$$ == AdfAgent.IE_PLATFORM && 10 <= $version$$14$$ ? new $AdfDvtCSS3Animator$$ : new AdfDvtAnimator
  }
  AdfDvtAnimator.$_animator$ = $animator_platform$$23$$;
  return AdfDvtAnimator.$_animator$;
};
AdfDvtAnimator.$ANIMATOR$ = AdfDvtAnimator.$getAnimator$();
AdfDvtAnimator.prototype.$supportsCSSTransition$ = function $AdfDvtAnimator$$$supportsCSSTransition$$() {
  return !1;
};
AdfDvtAnimator.prototype.animate = function $AdfDvtAnimator$$animate$($peer$$84$$, $animationObjects$$27$$, $animationDuration$$1$$, $callback$$99$$, $params$$47$$) {
  for (var $animObjs$$ = [], $isIE9$$ = AdfAgent.AGENT.getPlatform() == AdfAgent.IE_PLATFORM && 9 == AdfAgent.AGENT.getVersion(), $j$$79$$ = 0;$j$$79$$ < $animationObjects$$27$$.length;$j$$79$$++) {
    animationObject = $animationObjects$$27$$[$j$$79$$];
    var $animObject_properties$$76$$ = animationObject.properties, $alpha$$3$$ = $animObject_properties$$76$$.alpha, $right$$9$$ = $animObject_properties$$76$$.right;
    if (null != $alpha$$3$$ && !isNaN($alpha$$3$$) && $isIE9$$ || null != $right$$9$$ && !isNaN($right$$9$$)) {
      var $prop$$32$$ = {};
      null != $alpha$$3$$ && !isNaN($alpha$$3$$) && $isIE9$$ && ($prop$$32$$.alpha = $animObject_properties$$76$$.alpha);
      null == $right$$9$$ || isNaN($right$$9$$) || ($prop$$32$$.right = $animObject_properties$$76$$.right);
      $animObject_properties$$76$$ = {};
      $animObject_properties$$76$$.element = animationObject.element;
      $animObject_properties$$76$$.properties = $prop$$32$$;
      $animObjs$$.push($animObject_properties$$76$$);
    }
  }
  $peer$$84$$.$_animator$ = AdfDhtmlElementAnimator.animate(AdfDhtmlElementAnimator.$FRAME_METHOD_SLOW_FAST_SLOW$, $animationDuration$$1$$, $animationObjects$$27$$, null, AdfDvtAnimator.$animationComplete$, {peer:$peer$$84$$, callback:$callback$$99$$, params:$params$$47$$, animationObjects:$animationObjects$$27$$}, null);
  0 < $animObjs$$.length && $DvtElementAnimator$$.animate($animationDuration$$1$$, $animObjs$$);
};
AdfDvtAnimator.$animationComplete$ = function $AdfDvtAnimator$$animationComplete$$($args$$166$$) {
  var $callback$$100$$ = $args$$166$$.callback, $params$$48$$ = $args$$166$$.params;
  delete $args$$166$$.peer.$_animator$;
  null != $callback$$100$$ && $callback$$100$$.apply(null, $params$$48$$);
};
function $DvtElementAnimator$$($itemState$$, $frameCount$$) {
  this.Init($itemState$$, $frameCount$$);
}
AdfObject.createSubclass($DvtElementAnimator$$);
$DvtElementAnimator$$.prototype.Init = function $$DvtElementAnimator$$$$Init$($itemState$$1$$, $frameCount$$1$$) {
  $DvtElementAnimator$$.superclass.Init.call(this);
  this.$_itemState$ = $itemState$$1$$;
  this.$_startTime$ = (new Date).getTime();
  this.$_frameCount$ = $frameCount$$1$$;
};
$DvtElementAnimator$$.prototype.stop = function $$DvtElementAnimator$$$$stop$() {
  this.$_stopped$ = !0;
  window.clearInterval(this.$_intervalID$);
  $JSCompiler_StaticMethods__destroy$$(this);
};
$DvtElementAnimator$$.animate = function $$DvtElementAnimator$$$animate$($timeLength$$, $items$$24$$) {
  for (var $frameCount$$2_itemCount$$ = $items$$24$$.length, $JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$ = Array($frameCount$$2_itemCount$$), $i$$309$$ = 0;$i$$309$$ < $frameCount$$2_itemCount$$;$i$$309$$++) {
    var $item$$76_state$$12$$ = $items$$24$$[$i$$309$$], $finalProperties_finalRight$$ = $item$$76_state$$12$$.$properties$, $finalProperties_finalRight$$ = void 0 === $finalProperties_finalRight$$ ? $item$$76_state$$12$$.properties : $finalProperties_finalRight$$, $element$$95$$ = $item$$76_state$$12$$.element, $element$$95$$ = void 0 === $element$$95$$ ? $item$$76_state$$12$$.element : $element$$95$$, $item$$76_state$$12$$ = {}, $finalAlpha$$ = $finalProperties_finalRight$$.alpha;
    if (null != $finalAlpha$$ && !isNaN($finalAlpha$$)) {
      var $initialAlpha$$ = $element$$95$$.style.opacity;
      if (null == $initialAlpha$$ || "" == "" + $initialAlpha$$) {
        $initialAlpha$$ = 1;
      }
      $item$$76_state$$12$$.opacity = [$initialAlpha$$, $finalAlpha$$ / 100, !0];
    }
    $finalProperties_finalRight$$ = $finalProperties_finalRight$$.right;
    null == $finalProperties_finalRight$$ || isNaN($finalProperties_finalRight$$) || ($item$$76_state$$12$$.right = [parseInt($element$$95$$.style.right), $finalProperties_finalRight$$]);
    $JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$[$i$$309$$] = {element:$element$$95$$, state:$item$$76_state$$12$$};
  }
  $frameCount$$2_itemCount$$ = Math.max(1, Math.round($timeLength$$ * $DvtElementAnimator$$.$_FRAMES_PER_MILLISECOND$));
  AdfPage.PAGE.isAnimationEnabled() || ($frameCount$$2_itemCount$$ = 1);
  $JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$ = new $DvtElementAnimator$$($JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$, $frameCount$$2_itemCount$$);
  $JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$.$_animationStepCallback$ = $JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$.createCallback($JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$.$_animationStep$);
  $JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$.$_intervalID$ = self.setInterval($JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$.$_animationStepCallback$, Math.floor(1 / $DvtElementAnimator$$.$_FRAMES_PER_MILLISECOND$));
  return $JSCompiler_StaticMethods__start$self$$inline_4824_itemState$$2$$;
};
function $JSCompiler_StaticMethods__destroy$$($JSCompiler_StaticMethods__destroy$self$$) {
  delete $JSCompiler_StaticMethods__destroy$self$$.$_itemState$;
  delete $JSCompiler_StaticMethods__destroy$self$$.$_startTime$;
  delete $JSCompiler_StaticMethods__destroy$self$$.$_intervalID$;
  delete $JSCompiler_StaticMethods__destroy$self$$.$_animationStepCallback$;
  delete $JSCompiler_StaticMethods__destroy$self$$.$_stopped$;
}
$DvtElementAnimator$$.prototype.$_animationStep$ = function $$DvtElementAnimator$$$$$_animationStep$$() {
  if (!this.$_stopped$ && null != this.$_intervalID$) {
    if (this.$_performAfterAnimate$) {
      window.clearInterval(this.$_intervalID$), $JSCompiler_StaticMethods__destroy$$(this);
    } else {
      var $itemState$$3$$ = this.$_itemState$, $itemCount$$1$$ = $itemState$$3$$.length, $frameIndex$$ = Math.round($DvtElementAnimator$$.$_FRAMES_PER_MILLISECOND$ * ((new Date).getTime() - this.$_startTime$)), $frameCount$$3$$ = this.$_frameCount$, $isLastFrame$$ = !1;
      $frameIndex$$ >= $frameCount$$3$$ - 1 && (this.$_performAfterAnimate$ = $isLastFrame$$ = !0);
      for (var $j$$80$$ = 0;$j$$80$$ < $itemCount$$1$$;$j$$80$$++) {
        var $currentItemState_state$$13$$ = $itemState$$3$$[$j$$80$$], $element$$96$$ = $currentItemState_state$$13$$.element, $currentItemState_state$$13$$ = $currentItemState_state$$13$$.state, $pValue$$, $x$$97$$;
        for ($x$$97$$ in $currentItemState_state$$13$$) {
          $pValue$$ = $isLastFrame$$ ? $currentItemState_state$$13$$[$x$$97$$][1] : $DvtElementAnimator$$.$_computeFrameProperty$($frameIndex$$, parseFloat($currentItemState_state$$13$$[$x$$97$$][0]), parseFloat($currentItemState_state$$13$$[$x$$97$$][1]), $frameCount$$3$$), $currentItemState_state$$13$$[$x$$97$$][2] || ($pValue$$ += "px"), $DvtElementAnimator$$.$_renderFrameProperty$($element$$96$$, $pValue$$, $x$$97$$);
        }
      }
    }
  }
};
$DvtElementAnimator$$.$_renderFrameProperty$ = function $$DvtElementAnimator$$$$_renderFrameProperty$$($element$$97$$, $pValue$$1$$, $pName$$) {
  $element$$97$$.style[$pName$$] = $pValue$$1$$;
};
$DvtElementAnimator$$.$_computeFrameProperty$ = function $$DvtElementAnimator$$$$_computeFrameProperty$$($frameNumber$$3$$, $initialValue$$, $finalValue$$, $lastFrameNumber$$) {
  return $initialValue$$ + (Math.cos($frameNumber$$3$$ / $lastFrameNumber$$ * Math.PI + Math.PI) + 1) / 2 * ($finalValue$$ - $initialValue$$);
};
$DvtElementAnimator$$.$_FRAMES_PER_MILLISECOND$ = .06;
