public CallHelperProvider(QuickbloxClient client) { if (client == null) { throw new ArgumentNullException(nameof(client)); } chatXmppClient = client.ChatXmppClient; webSyncClient = client.WebSyncClient; chatXmppClient.MessageReceived += OnMessageReceived; webSyncClient.VideoChatMessage += OnVideoChatMessageReceived; #if WINDOWS_APP callOutgoingAudioTimer = new DispatcherTimer(); callOutgoingAudioTimer.Tick += OnCallOutgoingAudioTimer; callOutgoingAudioTimer.Interval = TimeSpan.FromMilliseconds(5000); callIncomingAudioTimer = new DispatcherTimer(); callIncomingAudioTimer.Tick += OnCallIncomingAudioTimer; callIncomingAudioTimer.Interval = TimeSpan.FromMilliseconds(5000); #else callOutgoingAudioTimer = new Timer(); callOutgoingAudioTimer.Elapsed += OnCallOutgoingAudioTimer; callOutgoingAudioTimer.Interval = 5000; callIncomingAudioTimer = new Timer(); callIncomingAudioTimer.Elapsed += OnCallIncomingAudioTimer; callIncomingAudioTimer.Interval = 5000; #endif }
public void Init(QuickbloxClient client) { this.chatXmppClient = client.ChatXmppClient; this.webSyncClient = client.WebSyncClient; }