예제 #1
0
 public void OnAVCallStateChanged(SipAVCallState newState, ushort sipCode, String description)
 {
     if (onAVCallEvent != null)
     {
         onAVCallEvent(this, new SipAVCallEventArgs(newState, sipCode, description));
     }
 }
예제 #2
0
        internal static String CallStateToString(SipAVCallState state)
        {
            switch (state)
            {
            case SipAVCallState.EarlyMedia:
            {
                return("Early Media");
            }

            case SipAVCallState.InCall:
            {
                return("In Call");
            }

            case SipAVCallState.Incoming:
            {
                return("Incoming");
            }

            case SipAVCallState.InProgress:
            {
                return("In Progress");
            }

            case SipAVCallState.RemoteRinging:
            {
                return("Ringing");
            }

            case SipAVCallState.Terminated:
            {
                return("Terminated");
            }

            case SipAVCallState.Terminating:
            {
                return("Terminating");
            }

            default:
            {
                return("Unknown");
            }
            }
        }
예제 #3
0
        virtual internal void Update()
        {
            String          remotePartyDisplayName = null;
            String          remotePartyNumber      = null;
            SipService      sipService             = rtServiceManager.Instance.SipService;
            SipAVCallState  callState         = SipAVCallState.None;
            SipSessionState registrationState = SipSessionState.None;

            if (sipService != null)
            {
                registrationState = sipService.RegistrationState;
                SipAVCall avCall = rtServiceManager.Instance.SipService.SipActiveAVCall;
                if (avCall != null)
                {
                    if (avCall.UriRemote != null)
                    {
                        remotePartyDisplayName = avCall.UriRemote.getDisplayName();
                        remotePartyNumber      = avCall.UriRemote.getUserName();
                        if (String.IsNullOrEmpty(remotePartyDisplayName))
                        {
                            remotePartyDisplayName = remotePartyNumber;
                        }
                    }
                    callState = avCall.State;
                }
            }

            RegistrationState = registrationState;
            if (!String.IsNullOrEmpty(remotePartyDisplayName)) // Keep previsous text
            {
                RemotePartyDisplayName = remotePartyDisplayName;
            }
            if (!String.IsNullOrEmpty(remotePartyNumber)) // Keep previsous text
            {
                RemotePartyNumber = remotePartyNumber;
            }
            if (callState != SipAVCallState.None)// Keep previsous text
            {
                CallState = callState;
            }
        }
예제 #4
0
 internal SipAVCallEventArgs(SipAVCallState state, ushort sipCode, String description)
 {
     mState = state;
     mSipCode = sipCode;
     mDescription = description;
 }
예제 #5
0
 public void OnAVCallStateChanged(SipAVCallState newState, ushort sipCode, String description)
 {
     if (onAVCallEvent != null)
     {
         onAVCallEvent(this, new SipAVCallEventArgs(newState, sipCode, description));
     }
 }
예제 #6
0
 internal SipAVCallEventArgs(SipAVCallState state, ushort sipCode, String description)
 {
     mState       = state;
     mSipCode     = sipCode;
     mDescription = description;
 }
예제 #7
0
파일: BasePage.cs 프로젝트: xolile/boghe
 internal static String CallStateToString(SipAVCallState state)
 {
     switch (state)
     {
         case SipAVCallState.EarlyMedia:
             {
                 return "Early Media";
             }
         case SipAVCallState.InCall:
             {
                 return "In Call";
             }
         case SipAVCallState.Incoming:
             {
                 return "Incoming";
             }
         case SipAVCallState.InProgress:
             {
                 return "In Progress";
             }
         case SipAVCallState.RemoteRinging:
             {
                 return "Ringing";
             }
         case SipAVCallState.Terminated:
             {
                 return "Terminated";
             }
         case SipAVCallState.Terminating:
             {
                 return "Terminating";
             }
         default:
             {
                 return "Unknown";
             }
     }
 }