/// <summary> /// Initializes this instance. /// </summary> private void Initialize() { _components = new Container(); _alphaAnimator = new ZeroitEXPicBoxAlphaAnimator(_components); _backColorAnimator = new Helpers.Animations.ControlBackColorAnimator(_components); _backColor2Animator = new ZeroitEXPicBoxColorAnimator(_components); _backColorGradientRotationAngleAnimator = new ZeroitEXPicBoxGradientAnimator(_components); _rotationAngleAnimator = new ZeroitEXPicBoxAngleAnimator(_components); _extraImageRotationAngleAnimator = new ZeroitEXPicBoxImageAnimator(_components); _zoomAnimator = new ZeroitEXPicBoxZoomAnimator(_components); _foreColorAnimator = new Helpers.Animations.ControlForeColorAnimator(_components); _textHaloColorAnimator = new ZeroitEXPicBoxTextAnimator(_components); _textRotationAngleAnimator = new ZeroitEXPicBoxTextAngleAnimator(_components); _textHaloWidthAnimator = new ZeroitEXPicBoxTextWidthAnimator(_components); _textZoomAnimator = new ZeroitEXPicBoxTextZoomAnimator(_components); _shadowOffsetAnimator = new ZeroitEXPicBoxShadowAnimator(_components); _imageOffsetAnimator = new ZeroitEXPicBoxImageOffsetAnimator(_components); _textOffsetAnimator = new ZeroitEXPicBoxTextOffsetAnimator(_components); }
/// <summary> /// Creates a new instance. /// </summary> /// <param name="animateExtraImageRotationAngle">Indicates whether the the extra image should be rotated.</param> /// <param name="animateColor">Indicates whether the colors should be animated.</param> /// <param name="color1">First color of the animation.</param> /// <param name="color2">Second color of the animation.</param> /// <param name="pictureBox">AnimatedPictureBox.</param> internal ZeroitStepAnimators(bool animateExtraImageRotationAngle, bool animateColor, Color color1, Color color2, ZeroitEXPicBoxAnimated pictureBox) { _pictureBox = pictureBox; _extraImageRotationAngleAnimator = new ZeroitEXPicBoxImageAnimator(); _extraImageRotationAngleAnimator.ZeroitEXPicBox = pictureBox; _extraImageRotationAngleAnimator.StartRotationAngle = 0f; _extraImageRotationAngleAnimator.EndRotationAngle = 360f; _extraImageRotationAngleAnimator.LoopMode = LoopMode.Repeat; _backColorAnimator = new ControlBackColorAnimator(); _backColorAnimator.Control = pictureBox; _backColorAnimator.StartColor = color1; _backColorAnimator.EndColor = color2; _backColorAnimator.LoopMode = LoopMode.Bidirectional; _backColor2Animator = new ZeroitEXPicBoxColorAnimator(); _backColor2Animator.ZeroitEXPicBox = pictureBox; _backColor2Animator.StartColor = color2; _backColor2Animator.EndColor = color1; _backColor2Animator.ParentAnimator = _backColorAnimator; }