public void PeerConnectionDisconnected(object sender, string message)
 {
     Console.WriteLine("User disconnected");
     Console.WriteLine("Here can working async compucting");
     ClientCell.RemoveRemoteControlling(Connection);
     Source.I420AVideoFrameReady += WritingVideo;
     UserDisconnected             = true;
     RestartTimer.Start();
 }
 public void PeerConnected(object sender, string message)
 {
     Console.WriteLine("User connected");
     Console.WriteLine("Here stop working async compucting");
     Source.I420AVideoFrameReady -= WritingVideo;
     ClientCell.AddRemoteControlling(Connection);
     UserDisconnected = false;
     RestartTimer.Stop();
 }
Example #3
0
        public ExceptionMassage(string str, int ErrorCount = 0, string CrashMethod = "")
        {
            InitializeComponent();

            Icon = Properties.Resources.mainico;
            //Misaki_Image.Controls.Add(label4);
            string[] result = str.Split(new char[] { '\n' });
            this.ErrorIndex.Lines = result;
            index = str;
            //描画先とするImageオブジェクトを作成する
            Bitmap canvas = new Bitmap(pictureBox1.Width, pictureBox1.Height);
            //ImageオブジェクトのGraphicsオブジェクトを作成する
            Graphics g = Graphics.FromImage(canvas);

            g.DrawIcon(SystemIcons.Error, 0, 0);
            g.Dispose();

            //PictureBox1に表示する
            pictureBox1.Image = canvas;
            ErrCnt            = ErrorCount;
            if (ErrCnt >= 2)
            {
                label1.Text = "MisakiEQは " + (ErrCnt + 1).ToString() + " 回連続で\n予期しないエラーが発生しました。";
                if (ErrCnt > 4)
                {
                    label1.ForeColor = System.Drawing.Color.Red;
                }
                label2.Text = "特定の手順で発生する場合は開発者にご報告ください。";
            }
            if (CrashMethod == "Void Application_was_crashed_by_user()")
            {
                label1.Text         = "MisakiEQを意図的にクラッシュさせました。";
                label1.ForeColor    = System.Drawing.Color.Black;
                label2.Text         = "水咲ちゃんはとても困っているようです。";
                UserReport.Text     = "意図的にクラッシュさせたため無効";
                UserReport.ReadOnly = true;
                UserReport.Enabled  = false;
                button1.Enabled     = false;
                label4.Text         = "";
            }
            if (ErrCnt >= 9)
            {
                RestartTimer.Stop();
                RestartMassage.Text = "繰り返し動作が停止しましたので自動再起動は無効になりました。";
            }
            getstring();
            CrashReport();
        }
Example #4
0
 private void UserReport_MouseClick(object sender, MouseEventArgs e)
 {
     RestartMassage.Text = "";
     RestartTimer.Stop();
 }