コード例 #1
0
        void drawRegionComplete()
        {
            Dictionary <string, int> dictionary = new Dictionary <string, int>();

            for (int j = 0; j < AcquirerVM.categoryCount; j++)
            {
                int count = 0;
                if (AcquirerVM.category[j])
                {
                    //int count=(from c in list_Item_Choosed
                    //         where c.CategoryId==j+1
                    //         select c.Num).Count();
                    var list = list_Item_Choosed.Where(c => c.CategoryId == j + 1);
                    foreach (var item in list)
                    {
                        count += item.Num;
                    }

                    //dictionary.Add(AcquirerVM.categoryStr[j] + "  ", list_Item_Choosed.Where(c => c.CategoryId == j + 1).);
                    dictionary.Add(AcquirerVM.categoryStr[j] + "  ", count);
                }
            }
            Storyboard3.AutoReverse = false;
            Storyboard3.Begin();

            control_Menu.lb_Category_Count.ItemsSource = dictionary;
            control_Menu.Height     = 500;
            control_Menu.Width      = 374;
            control_Menu.Visibility = Visibility.Visible;
            //MenuContent.Children.Clear();
            //MenuContent.Children.Add(control_Menu);
            //dd.IsHitTestVisible = false;
        }
コード例 #2
0
 private void ck4_Tapped(object sender, TappedRoutedEventArgs e)
 {
     c5 = 1;
     if ((d == 0) && (final == 0))
     {
         TxtBox_Scoreint.Text = Convert.ToString(score = score + 1);
         ck4.Source           = new Windows.UI.Xaml.Media.Imaging.BitmapImage(new Uri(this.BaseUri, "Assets/dead-cockroach.png"));
         Story_ck4.Pause();
         Story_ck6.Begin();
         ck6.Visibility = Visibility.Visible;
         Story_ck5.Begin();
         ck5.Visibility = Visibility.Visible;
         d = 1;
     }
     if ((c1 == 1) && (c2 == 1) && (c3 == 1) && (c4 == 1) && (c5 == 1) && (c6 == 1) && (c7 == 1))
     {
         Btn_Level2.Visibility      = Visibility.Visible;
         TxtBox_congrats.Visibility = Visibility.Visible;
         Storyboard1.Pause();
         Storyboard2.Pause();
         Storyboard3.Pause();
         Story_ck3.Pause();
         Story_ck4.Pause();
         Story_ck5.Pause();
         Story_ck6.Pause();
     }
 }
コード例 #3
0
        private void Button_Click(object sender, RoutedEventArgs e)
        {
            geldimi = false;
            foreach (Label item in sp.Children)
            {
                if (tbtahmin.Text == item.Tag.ToString() && item.Tag.ToString() != "")
                {
                    geldimi = true;


                    item.Background     = new SolidColorBrush(Colors.White);
                    item.Content        = item.Tag;
                    sptahmin.Visibility = Visibility.Collapsed;
                }
                else if (tbtahmin.Text != item.Tag.ToString())
                {
                    sptahmin.Visibility = Visibility.Collapsed;
                }
            }
            if (hareket == true && geldimi == true)
            {
                Storyboard2.Begin();
                hareket = false;
            }
            else if (geldimi == true)
            {
                Storyboard3.Begin();
                hareket = true;
            }
        }
コード例 #4
0
        protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
        {
            Storyboard3.AutoReverse = true;
            Storyboard3.Duration    = new Duration(new TimeSpan(0, 0, 0, 0, 600));
            Storyboard3.Begin();
            Storyboard3.SeekAlignedToLastTick(new TimeSpan(0, 0, 0, 0, 100));

            base.OnNavigatedTo(e);
        }
コード例 #5
0
 void btnAppBarOK_Click(object sender, EventArgs e)
 {
     if (control_Post_FillMessage.items_Post.Count != control_Post_FillMessage.Items_Image.Count)
     {
         MessageBox.Show("Please take the photos of resourse you post! ");
         return;
     }
     // Image image_front = (Image)sender;
     // image_front.Source = new BitmapImage(new Uri("/Image_Post/arrow_active.png", UriKind.Relative));
     Storyboard3.AutoReverse = true;
     Storyboard3.Begin();
     NavigationService.Navigate(new Uri("/Views/PostSuccessPage.xaml", UriKind.Relative));
 }
コード例 #6
0
        private void ck2_Tapped(object sender, TappedRoutedEventArgs e)
        {
            c3 = 1;

            if ((b == 0) && (final == 0))
            {
                TxtBox_Scoreint.Text = Convert.ToString(score = score + 1);
                ck2.Source           = new Windows.UI.Xaml.Media.Imaging.BitmapImage(new Uri(this.BaseUri, "Assets/dead-cockroach.png"));
                Storyboard3.Pause();
                Story_ck3.Begin();
                ck3.Visibility = Visibility.Visible;
                b = 1;
            }
        }
コード例 #7
0
        void timer_Tick(object sender, object e)
        {
            maxTime--;
            timeleft.Text = maxTime.ToString();

            if (maxTime == 0)
            {
                timer.Stop();
                //stopStoryboard1();
                this.Frame.Navigate(typeof(Zombiescorepage));
            }

            if (maxTime == 9)
            {
                Storyboard2.Begin();
            }
            if (maxTime == 8)
            {
                Storyboard3.Begin();
            }
            if (maxTime == 7)
            {
                Storyboard4.Begin();
            }
            if (maxTime == 6)
            {
                Storyboard5.Begin();
            }
            if (maxTime == 5)
            {
                Storyboard6.Begin();
            }
            if (maxTime == 4)
            {
                Storyboard7.Begin();
            }
            if (maxTime == 3)
            {
                Storyboard8.Begin();
            }
            if (maxTime == 2)
            {
                Storyboard9.Begin();
            }
            if (maxTime == 1)
            {
                Storyboard10.Begin();
            }
        }
コード例 #8
0
        void Storyboard1_Completed(object sender, object e)
        {
            lady.Source = new Windows.UI.Xaml.Media.Imaging.BitmapImage(new Uri(this.BaseUri, "Assets/fear.png"));
            final       = 1;
            Media_shout.Play();

            Storyboard1.Pause();
            Storyboard2.Pause();
            Storyboard3.Pause();
            Story_ck3.Pause();
            Story_ck4.Pause();
            Story_ck5.Pause();
            Story_ck6.Pause();

            TxtBox_gameOver.Visibility = Visibility.Visible;
            Btn_Retry.Visibility       = Visibility.Visible;
        }
コード例 #9
0
        public UploadingControl()
        {
            InitializeComponent();

            Loaded += (sender, args) =>
            {
                Storyboard1.Begin();
                Storyboard2.Begin();
                Storyboard3.Begin();
            };

            Unloaded += (sender, args) =>
            {
                Storyboard1.Stop();
                Storyboard2.Stop();
                Storyboard3.Stop();
            };
        }
コード例 #10
0
        protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
        {
            //Storyboard1.AutoReverse = true;
            //Storyboard1.BeginTime=new TimeSpan(0, 0, 0,0, 200);
            //Storyboard1.Duration = new Duration(new TimeSpan(0, 0, 0, 1000));
            //Storyboard1.FillBehavior = FillBehavior.Stop;
            //Storyboard1.Begin();
            // Storyboard1.AutoReverse = true;
            //  Storyboard1.Duration = new Duration(new TimeSpan(0,0,0,1));

            //Storyboard1.Begin();
            //Storyboard1.SkipToFill();
            Storyboard3.Begin();
            Storyboard3.BeginTime = new TimeSpan(0, 0, 0, 0, 600);
            while (NavigationService.BackStack.Any())
            {
                NavigationService.RemoveBackEntry();
            }

            base.OnNavigatedTo(e);
        }
コード例 #11
0
ファイル: mazerunner.xaml.cs プロジェクト: sgrmhrzn/hackathon
        private void Image_Tapped(object sender, TappedRoutedEventArgs e)
        {
            timer          = new DispatcherTimer();
            timer.Interval = TimeSpan.FromSeconds(1);
            timer.Tick    += timer_Tick;
            timer.Start();

            x = x + 1;

            Storyboard2.Begin();
            Storyboard3.Begin();
            Storyboard4.Begin();
            Storyboard5.Begin();
            Storyboard6.Begin();
            Storyboard7.Begin();
            Storyboard8.Begin();
            Storyboard9.Begin();
            Storyboard10.Begin();
            Storyboard11.Begin();
            Storyboard12.Begin();
        }
コード例 #12
0
 private void Button3_Click(object sender, RoutedEventArgs e)
 {
     Storyboard3.Children[0].SetValue(DoubleAnimation.FromProperty, Translation3.X);
     Storyboard3.Children[0].SetValue(DoubleAnimation.ToProperty, Translation3.X > 0 ? 0 : 200);
     Storyboard3.Begin();
 }
コード例 #13
0
ファイル: Tile2.xaml.cs プロジェクト: Kelin-Hong/Becle.Phone
        void timer_Tick(object sender, EventArgs e)
        {
            // image10.Clip = new RectangleGeometry() { Rect = new Rect(0, 0, image10.Width / 2, image10.Height / 2) };
            int i = r.Next(12);
            int j = r.Next(5);

            switch (i)
            {
            case 1:
                image1.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative));    Storyboard1.Begin(); break;

            case 2: image2.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative));  Storyboard2.Begin(); break;

            case 3: image3.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); Storyboard3.Begin(); break;

            case 4: image4.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); Storyboard4.Begin(); break;

            case 5: image5.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); Storyboard5.Begin(); break;

            case 6: image6.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); Storyboard6.Begin(); break;

            case 7: image7.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); Storyboard7.Begin(); break;

            case 8: image8.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); Storyboard8.Begin(); break;

            case 9: image9.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); Storyboard9.Begin(); break;

            case 10: image10.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); image10.Visibility = Visibility.Collapsed; break;

            case 11: image10.Visibility = Visibility.Visible; break;
                //case 10:
                //    {
                //        //timer.Stop();
                //        //int jj = r.Next(4);

                //       // image10.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + j + ".jpg", UriKind.Relative)); image10.Clip = new RectangleGeometry() { Rect = new Rect(0, 0, 60, 60) }; Storyboard1.Begin(); break;
                //        //image1.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + jj + ".jpg", UriKind.Relative)); image1.Height = 60; image1.Width = 60; image1.Clip = new RectangleGeometry() { Rect = new Rect(0, 0, 30, 30) };  image1.Width = 60; image1.Height = 60; Storyboard1.Begin();
                //        //image2.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + jj + ".jpg", UriKind.Relative)); image2.Height = 60; image2.Width = 60; image2.Clip = new RectangleGeometry() { Rect = new Rect(30, 0, 30, 30) }; image2.Width = 120; image2.Height = 120; Storyboard2.Begin();
                //        //image5.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + jj + ".jpg", UriKind.Relative)); image5.Height = 120; image5.Width = 120; image5.Clip = new RectangleGeometry() { Rect = new Rect(0, 60, 60, 60) }; Storyboard5.Begin();
                //        //image4.Source = new BitmapImage(new Uri("/Image_Home/Avatar/" + jj + ".jpg", UriKind.Relative)); image4.Height = 120; image4.Width = 120; image4.Clip = new RectangleGeometry() { Rect = new Rect(60,60, 60, 60) }; Storyboard4.Begin();

                //    }break;
            }
            ;



            // if (i == 1)
            // Storyboard1.Begin();
            //  else
            // Storyboard2.Begin();
        }
コード例 #14
0
 void Storyboard3_Completed(object sender, object e)
 {
     Storyboard3.Begin();
 }
コード例 #15
0
 private void MoveButtonO(object sender, MouseEventArgs e)
 {
     Storyboard3.Begin();
 }
コード例 #16
0
 public MainPage()
 {
     this.InitializeComponent();
     Storyboard3.Begin();
     Storyboard3.Completed += Storyboard3_Completed;
 }
コード例 #17
0
 private void textBlock2_MouseEnter(object sender, MouseEventArgs e)
 {
     Storyboard3.Begin();
 }