コード例 #1
0
        public void SlideUpAlert()
        {
            if (alertBarVisible)
            {
                return;
            }

            DoubleAnimation animation = new DoubleAnimation();

            animation.From     = 0d;
            animation.To       = 30d;
            animation.Duration = TimeSpan.FromSeconds(.5d);

            alertBarVisible = true;

            AlertBar.BeginAnimation(HeightProperty, animation);
        }
コード例 #2
0
        public void SlideDownAlert()
        {
            if (!alertBarVisible)
            {
                return;
            }

            DoubleAnimation animation = new DoubleAnimation();

            animation.From     = 30d;
            animation.To       = 0d;
            animation.Duration = TimeSpan.FromSeconds(.5d);

            alertBarVisible       = false;
            alertBarPriorityAlert = false;

            AlertBar.BeginAnimation(HeightProperty, animation);
        }