Exemplo n.º 1
0
        /* Implement IntCall. */
        public void onCallState(CallInfoRT info)
        {
            switch (info.state)
            {
            case INV_STATE.PJSIP_INV_STATE_CALLING:
                sendCallState("Calling");
                break;

            case INV_STATE.PJSIP_INV_STATE_INCOMING:
                sendCallState("Incoming");
                break;

            case INV_STATE.PJSIP_INV_STATE_CONNECTING:
                sendCallState("Connecting");
                break;

            case INV_STATE.PJSIP_INV_STATE_CONFIRMED:
                sendCallState("Connected");
                break;

            case INV_STATE.PJSIP_INV_STATE_DISCONNECTED:
                sendCallState("Disconnected");
                Current.EndCall();
                break;
            }
        }
Exemplo n.º 2
0
        /* Implement IntAccount. */
        public void onIncomingCall(CallInfoRT info)
        {
            if (Current.VoipCall != null)
            {
                /* Only one active call */
                return;
            }

            Current.RequestNewIncomingCall(info.remoteContact,
                                           info.remoteUri,
                                           "Pjsua");
        }