Example #1
0
        private void ScAnim_AnimationEvent(ScAnimation scAnimation)
        {
            if (mouseEnterLinear == null)
            {
                return;
            }

            float value = mouseEnterLinear.GetCurtValue();

            enterHaloAlpha = (int)value;

            if (mouseEnterLinear.IsStop)
            {
                mouseEnterAnim.Stop();
                mouseEnterLinear = null;

                if (value == endColor)
                {
                    StartProgressAnim(endColor, startColor);
                }
                else
                {
                    StartProgressAnim(startColor, endColor);
                }
            }

            Refresh();
        }
Example #2
0
        private void ScAnim_AnimationEvent(ScAnimation scAnimation)
        {
            alpha = (int)linear.GetCurtValue();

            if (linear.IsStop)
            {
                scAnimation.Stop();
            }

            Refresh();
        }
Example #3
0
        private void ScAnim_AnimationEvent1(ScAnimation scAnimation)
        {
            growHeight = mouseEnterLinear1.GetCurtValue();

            if (mouseEnterLinear1.IsStop)
            {
                mouseEnterAnim1.Stop();

                StartProgressAnim(startColor, endColor);
            }

            Refresh();
        }
Example #4
0
        private void ZoomAnim_AnimationEvent(ScAnimation scAnimation)
        {
            animZoom = zoomLinear.GetCurtValue();

            ScaleX = animZoom;
            ScaleY = animZoom;

            if (zoomLinear.IsStop)
            {
                scAnimation.Stop();
            }

            Refresh();
        }
Example #5
0
        private void ScaleAnim_AnimationEvent(ScAnimation scAnimation)
        {
            animScaleValue = linear.GetCurtValue();

            if (animScaleValue >= 1.0f)
            {
                StopScaleAnim();
            }

            if (AnimScaleEvent != null)
            {
                AnimScaleEvent();
            }
        }
Example #6
0
        private void VisibleAnim_AnimationEvent(ScAnimation scAnimation)
        {
            Opacity = opacityLinear.GetCurtValue();

            if (opacityLinear.IsStop)
            {
                scAnimation.Stop();
                if (Opacity == 0)
                {
                    visible = false;
                }
            }

            Refresh();
        }
Example #7
0
        private void ScAnim_AnimationEvent(ScAnimation scAnimation)
        {
            if (progressLinear == null)
            {
                return;
            }

            animProgress = progressLinear.GetCurtValue();

            if (progressLinear.IsStop)
            {
                scAnimation.Stop();
                progressLinear = null;
                StartProgressAnim();
            }

            Refresh();
        }
Example #8
0
        private void RowLayerAnim_AnimationEvent(ScAnimation scAnimation)
        {
            float v   = 0;
            float len = rowLayerAnimLinear.GetCurtValue();

            if (rowLayerAnimLinear.IsStop)
            {
                scAnimation.Stop();
            }

            for (int i = 0; i < controls.Count; i++)
            {
                ScLayer rowlayer = controls[i];
                v = len * i * animBaseSpaceScale + animPos;
                rowlayer.Location = new PointF(v, rowlayer.Location.Y);
            }

            Refresh();
        }
Example #9
0
        private void SlideScreenAnim_AnimationEvent(ScAnimation scAnimation)
        {
            float pos = slideAnimLinear.GetCurtValue();

            if (slideAnimLinear.IsStop)
            {
                scAnimation.Stop();

                if (slideDirection == -1)
                {
                    rightScreen.StartRowLayerBackAnim();
                }
                else
                {
                    leftScreen.StartRowLayerBackAnim();
                }
            }

            SetSlidePos(pos);
            Refresh();
        }
Example #10
0
        private void HaloAnim_AnimationEvent(ScAnimation scAnimation)
        {
            animHaloAlphaScale = haloLinear.GetCurtValue();


            if (haloLinear.IsStop)
            {
                scAnimation.Stop();

                if (endHaloAlphaScale == 1.0f)
                {
                    endHaloAlphaScale = 0.3f;
                }
                else
                {
                    endHaloAlphaScale = 1.0f;
                }

                StartHaloAnim();
            }

            Refresh();
        }
Example #11
0
        private void ScAnim_AnimationEvent(ScAnimation scAnimation)
        {
            int r, g, b;

            r = (int)linearR.GetCurtValue();
            g = (int)linearG.GetCurtValue();
            b = (int)linearB.GetCurtValue();

            color = Color.FromArgb(r, g, b);

            Refresh();
            Update();

            if (linearR.IsStop && linearG.IsStop && linearB.IsStop)
            {
                scAnimation.Stop();

                if (AnimalStopEvent != null)
                {
                    AnimalStopEvent(this);
                }
            }
        }