示例#1
0
        private void btnStatus_Click(object sender, EventArgs e)
        {
            switch (PhoneStatus)
            {
            case PhoneStatus.Ringing:
            {
                PickupPhone();
                break;
            }


            case PhoneStatus.Talking:
            {
                HangupPhone();
                break;
            }

            case PhoneStatus.ReadyHuman:
            {
                btnStatus.Text      = "Talking (Hang Up)";
                btnStatus.BackColor = Color.PowderBlue;
                PhoneStatus         = PhoneStatus.Talking;
                CallLogger.LogInteraction(InteractionWho.Phone, InteractionWhat.Pickup, SystemColors.Desktop, "");
                currentPhoneNum = outgoingPhoneNumber;
                SystemController.Instance.Office.PhoneDialingIn(Settings.Default.DefaultFromNumber, outgoingPhoneNumber);
                break;
            }
            }
        }
示例#2
0
 private void PickupPhone()
 {
     btnStatus.Text      = "Talking (Hang Up)";
     btnStatus.BackColor = Color.PowderBlue;
     PhoneStatus         = PhoneStatus.Talking;
     CallLogger.LogInteraction(InteractionWho.Phone, InteractionWhat.Pickup, SystemColors.Desktop, "");
     SystemController.Instance.Office.PhonePickedUp(currentPhoneNum, DefaultPhoneStatus == PhoneStatus.ReadyMachine?true:false);
 }
示例#3
0
        private void SubmitBuffer()
        {
            CallLogger.LogInteraction(InteractionWho.Phone, InteractionWhat.Say, SystemColors.Desktop, lblBuffer.Text.Replace("Buffer: ", ""));
            tmrDial.Enabled = false;

            SystemController.Instance.Office.PhoneSendingDigits(PhoneNumber, lblBuffer.Text.Replace("Buffer: ", ""));
            lblBuffer.Text    = "";
            lblBuffer.Visible = false;
        }
示例#4
0
 private void HangupPhone()
 {
     PhoneStatus = DefaultPhoneStatus;
     SystemController.Instance.Office.PhoneHungUp(outgoingPhoneNumber);
     CallLogger.LogInteraction(InteractionWho.Phone, InteractionWhat.Hangup, SystemColors.Desktop, "");
 }