예제 #1
0
        void cell_MouseDown(object sender, MouseEventArgs e)
        {
            if (e.Button == MouseButtons.Right)
            {
                cell.Image = Properties.Resources.zero;
                check      = check.Remove((int)cell.Tag, 1);
                check      = check.Insert((int)cell.Tag, "0");
            }
            else
            {
                cell.Image = (Bitmap)Properties.Resources.ResourceManager.GetObject("zadanie" + gamenum);
                check      = check.Remove((int)cell.Tag, 1);
                check      = check.Insert((int)cell.Tag, "1");
            }

            if (check == Properties.Resources.ResourceManager.GetObject("Game" + gamenum).ToString())
            {
                //Вы решили кроссворд!
                game_timer.Stop();
                RightSolution1_Frm RsolFrm = new RightSolution1_Frm();
                RsolFrm.pictureBox1.Image = (Bitmap)Properties.Resources.ResourceManager.GetObject("win" + gamenum);
                RsolFrm.ShowDialog();
                RsolFrm.Dispose();
            }
        }
예제 #2
0
        private void btn_GiveUp_Click(object sender, EventArgs e)
        {
            game_timer.Stop();
            RightSolution1_Frm RsolFrm = new RightSolution1_Frm();

            RsolFrm.pictureBox1.Image = (Bitmap)Properties.Resources.ResourceManager.GetObject("win" + gamenum);
            RsolFrm.label1.Text       = "Правильное решение: ";
            RsolFrm.ShowDialog();
            RsolFrm.Dispose();
        }