Esempio n. 1
0
        public override void onEntry()
        {
            _smref.Incoming = true;

            int sessionId = _smref.Session;

            if ((_smref.Config.CFUFlag == true) && (_smref.Config.CFUNumber.Length > 0))
            {
                CallProxy.serviceRequest(sessionId, (int)EServiceCodes.SC_CFU, _smref.Config.CFUNumber);
            }
            else if (_smref.Config.DNDFlag == true)
            {
                CallProxy.serviceRequest(sessionId, (int)EServiceCodes.SC_DND, "");
            }
            else if (_smref.Config.AAFlag == true)
            {
                this.acceptCall(sessionId);
            }
            else
            {
                CallProxy.alerted(sessionId);
                _smref.Type = ECallType.EMissed;
                MediaProxy.playTone(ETones.EToneRing);
            }

            // if CFNR active start timer
            if (_smref.Config.CFNRFlag)
            {
                _smref.startTimer(ETimerType.ENOREPLY);
            }
        }
Esempio n. 2
0
        internal override void OnEntry()
        {
            // set incoming call flags
            _smref.Incoming = true;

            int sessionId = SessionId;

            // Start no response timer
            _smref.StartTimer(ETimerType.ENORESPONSE);

            CallProxy.alerted();
            _smref.Type = ECallType.EMissed;
            MediaProxy.playTone(ETones.EToneRing);

            // if CFNR active start timer
            if (_smref.Config.CFNRFlag)
            {
                _smref.StartTimer(ETimerType.ENOREPLY);
            }
            // auto answer call (if single call)
            if ((_smref.Config.AAFlag == true) && (_smref.NumberOfCalls == 1))
            {
                this.acceptCall();
            }
        }
Esempio n. 3
0
        internal override void OnEntry()
        {
            // set incoming call flags
            _smref.Incoming = true;

            int sessionId = SessionId;

            // drop call if pause flag
            if (_smref.Config.PauseFlag)
            {
                this.endCall();

                return;
            }

            // Start no response timer
            _smref.StartTimer(ETimerType.ENORESPONSE);

            CallProxy.alerted();
            _smref.Type = ECallType.EMissed;

            // Don't play any sounds while active calls persist
            if (_smref.Config.AudioPlayOnIncoming && (this._smref.NumberOfCalls == 1 || _smref.Config.AudioPlayOnIncomingAndActive))
            {
                Task.Factory.StartNew(() => MediaProxy.playTone(ETones.EToneRing), TaskCreationOptions.PreferFairness);
            }

            // if CFNR active start timer
            if (_smref.Config.CFNRFlag)
            {
                _smref.StartTimer(ETimerType.ENOREPLY);
            }

            // auto answer call (if single call)
            if ((_smref.Config.AAFlag == true) && (_smref.NumberOfCalls == 1))
            {
                this.acceptCall();
            }
        }