AndersMalmgren / FreePIE

Programmable Input Emulator
649 stars 144 forks source link

Problem with speech to test if speaking #137

Open Frenchy62620 opened 7 years ago

Frenchy62620 commented 7 years ago

to fix some bugs its necessary to add event started to this method

        private void EnsureSynthesizer()
        {
            if (synth == null)
            {
                synth = new SpeechSynthesizer();
                synth.SetOutputToDefaultAudioDevice();
                synth.SpeakCompleted += (s, e) => Speaking = false;
                synth.SpeakStarted += (s, e) => Speaking = true;
            }
        }

and you could drop the line

Speaking = true;

from the method say