コード例 #1
0
ファイル: MiscHandler.cs プロジェクト: BahNahNah/MLRat
 public static void TextToSpeechContextCallback(IClient[] clients)
 {
     if (clients.Length < 1)
         return;
     string say = string.Empty;
     int speed = 0;
     using (formTextToSpeech tts = new formTextToSpeech())
     {
         if (tts.ShowDialog() == System.Windows.Forms.DialogResult.OK)
             return;
         say = tts.TextToSay;
         speed = tts.SaySpeed;
     }
     foreach (IClient c in clients)
         c.Send((byte)NetworkCommand.TextToSpeech, say, speed);
 }
コード例 #2
0
        public static void TextToSpeechContextCallback(IClient[] clients)
        {
            if (clients.Length < 1)
            {
                return;
            }
            string say   = string.Empty;
            int    speed = 0;

            using (formTextToSpeech tts = new formTextToSpeech())
            {
                if (tts.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                {
                    return;
                }
                say   = tts.TextToSay;
                speed = tts.SaySpeed;
            }
            foreach (IClient c in clients)
            {
                c.Send((byte)NetworkCommand.TextToSpeech, say, speed);
            }
        }