Esempio n. 1
0
 private void Form1_Load(object sender, EventArgs e)
 {
     this.MsgWin = new ProcMessageWindow();
     D300SysUI_SetResumeRegister(this.MsgWin.Hwnd, 0x4010);
     this.panel1.Visible = false;
     this.comboBox1.SelectedIndex = 0;
     S_START_SPOT_NUM = stationID();
     this.N_START_SPOT_NUM = int.Parse(S_START_SPOT_NUM);
     this.f2 = new Form2();
     this.f2.Show();
     this.f2.Visible = false;
     call.OnActiveEvent += new Call.NotifyEvent(this.OnCallAnwserEvent);
     call.OnIncomingEvent += new Call.NotifyEvent(this.OnCallInEvent);
     call.OnHangupEvent += new Call.NotifyEvent(this.OnCallHangupEvent);
     call.OnDialingEvent += new Call.NotifyEvent(this.OnCallDialingEvent);
     ras.OnConnectedEvent += new Ras.NotifyEvent(this.OnConnectedEvent);
     ras.OnDisconnectedEvent += new Ras.NotifyEvent(this.OnDisconnectedEvent);
     if (this.checknet())
     {
     this.NetPIC.BackColor = Color.Green;
     }
     else
     {
     this.NetPIC.BackColor = Color.Red;
     }
     Initialize.Init();
     this.backgroundwork();
     this.clearPropShow();
 }
Esempio n. 2
0
        //加载
        private void Form1_Load(object sender, EventArgs e)
        {
            this.MsgWin = new ProcMessageWindow();
            D300SysUI_SetResumeRegister(MsgWin.Hwnd, WM_RESUME);
            //   D300SysUI_SetResumeRegister(mycallback, WM_RESUME);
            panel1.Visible = false;
            Initialize.Init();
            ras = Ras.GetInstance();
            call = Call.GetInstance();
            comboBox1.SelectedIndex = 0;
            S_START_SPOT_NUM = stationID();
            N_START_SPOT_NUM = int.Parse(S_START_SPOT_NUM);
            f2 = new Form2();
            f2.Show();
            f2.Visible = false;
            call.OnActiveEvent += new Call.NotifyEvent(OnCallAnwserEvent);
            call.OnIncomingEvent += new Call.NotifyEvent(OnCallInEvent);
            call.OnHangUpEvent += new Call.NotifyEvent(OnCallHangupEvent);
            call.OnDialingEvent += new Call.NotifyEvent(OnCallDialingEvent);
            call.OnMissingEvent += new Call.NotifyEvent(call_OnMissingEvent);
            ras.OnConnectedEvent += new Ras.NotifyEvent(OnConnectedEvent);
            ras.OnDisconnectedEvent += new Ras.NotifyEvent(OnDisconnectedEvent);

            if (checknet())
                NetPIC.BackColor = Color.Green;
            else
                NetPIC.BackColor = Color.Red;

            //      pictureBox1.Visible = false;
            //      pictureBox2.Visible = false;
            SEUIC.Phone.Initialize.Init();
            backgroundwork();
            clearPropShow();
        }