LinphoneCallInProgressAgent.cs 1.7 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13
/*
LinphoneCallInProgressAgent.cs
Copyright (C) 2015  Belledonne Communications, Grenoble, France
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
14
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
15 16 17
*/

using Microsoft.Phone.Networking.Voip;
18
using Linphone.Core;
19 20 21 22 23 24 25 26 27 28 29
using Linphone.Core.OutOfProcess;
using System.Diagnostics;

namespace Linphone.Agents
{
    public class LinphoneCallInProgressAgent : VoipCallInProgressAgent
    {
        public LinphoneCallInProgressAgent() : base()
        {
        }

30 31
        /// <summary>
        /// Called when the first call has started.
32 33 34
        /// </summary>
        protected override void OnFirstCallStarting()
        {
35
            Debug.WriteLine("[LinphoneCallInProgressAgent] The first call has started.");
Ghislain MARY's avatar
Ghislain MARY committed
36
            AgentHost.OnAgentStarted();
37 38
        }

39 40
        /// <summary>
        /// Called when the last call has ended.
41 42 43 44 45 46 47
        /// </summary>
        protected override void OnCancel()
        {
            Debug.WriteLine("[LinphoneCallInProgressAgent] The last call has ended. Calling NotifyComplete");
            base.NotifyComplete();
        }
    }
48
}