예제 #1
0
파일: Form1.cs 프로젝트: 20chan/OldProjects
        private CPoint GetScreenPos(CPoint _p)
        {
            float real_X = 0, real_Y = 0;

            try
            {
                real_X = (_p.X * (screen_Size.Width) / panel1.Size.Width) / screen_Size.Width;
                real_Y = (_p.Y * (screen_Size.Height) / panel1.Size.Height) / screen_Size.Height;
            }
            catch { }
            return(new CPoint(real_X, real_Y));
        }
예제 #2
0
파일: Form1.cs 프로젝트: 20chan/OldProjects
 private void AddPoint(Graphics _graphic, CPoint _penelPoing)
 {
     try
     {
         _graphic = this.panel1.CreateGraphics();
         _graphic.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias;
         _graphic.DrawArc(p, _penelPoing.X, _penelPoing.Y, 1, 1, 0, 360);
         //_graphic.DrawLine(p, new Point(_point.X - 1, _point.Y - 1), new Point(_point.X + 1, _point.Y + 1));
         //_graphic.DrawLine(p, new Point(_point.X - 1, _point.Y + 1), new Point(_point.X + 1, _point.Y - 1));
         points.Add(_penelPoing);
     }
     catch { }
 }
예제 #3
0
파일: Form1.cs 프로젝트: 20chan/OldProjects
 private void Play()
 {
     //this.Hide();
     System.Threading.Thread.Sleep(2000);
     foreach (CPoint po in points)
     {
         CPoint p = GetScreenPos(po);
         //move_Click(po);
         Send_Cloud(p.Y.ToString(), this.materialSingleLineTextField1.Text, toSend, p.X.ToString());
         //System.Threading.Thread.Sleep(timeGap);
         //type_String(toSend);
         //SendKeys.SendWait(toSend);
         //System.Threading.Thread.Sleep(timeGap);
         //KeyboardHook.MakeKeyEvent(Keys.D, KeyEventType.CLICK);
         //KeyboardHook.MakeKeyEvent(Keys.Enter, KeyEventType.CLICK);
         //System.Threading.Thread.Sleep(timeGap);
         //if (!this.Created) return;
     }
     //this.Show();
     state = State.IDLE;
 }