Exemple #1
0
        private void Main_RButtom(object sender, EventArgs e)
        {
            synth.SpeakAsyncCancelAll();
            if (Main.voiceDP.Voice != 0)
            {
                if (w.NumberPart == 7)
                {
                    synth.SpeakAsync("to " + w.EN);
                }
                else
                {
                    synth.SpeakAsync(w.EN);
                }
            }



            Word dd2 = new Word();

            for (int i = 0; i < RadioButList().Count; i++)
            {
                if (RadioButList().ElementAt(i).IsChecked == true)
                {
                    bool TF = quest.ElementAt(i) == w;
                    if (TF)
                    {
                        threount[0]++;
                        Main.TruOrFals.Foreground = Brushes.White;
                        //  Method.Blink(Main.TruOrFals, Brushes.White);
                        RadioButList().ElementAt(i).Foreground = Brushes.Green;
                    }
                    else
                    {
                        threount[1]++;
                        Main.TruOrFals.Foreground = Brushes.Red;
                        dd2 = quest.ElementAt(i);
                        RadioButList().ElementAt(i).Foreground = Brushes.DarkRed;
                        for (int j = 0; j < RadioButList().Count; j++)
                        {
                            if (quest.ElementAt(j) == w)
                            {
                                RadioButList().ElementAt(j).Foreground = Brushes.DarkGreen;
                            }
                        }
                    }



                    Main.TruOrFals.Content = Method.TrueOrFalse(TF);

                    Method.MethodReadCount(TF, w, dd2);
                }
            }


            foreach (var r in RadioButList())
            {
                r.IsEnabled = false;
            }

            Main.LvL.Content   = ForSerial.Lvl + ForSerial.sravnenieOstatka;
            Main.Progres.Value = Engl.Kateroris.DependencyPropertySub.LvlProgres;

            methodSTARS();


            // System.Console.WriteLine(synth.Voice.Name.ElementAt(i).ToString());
            //   synth.SelectVoice( synth.Voice.Name.ElementAt(i).ToString());
            // Speak a string.
        }