void sender_OnRequest(RtspClient sender, RtspMessage request) { if (request != null) { //Disable keep alives if indicated Client.DisableKeepAliveRequest = checkBox1.Checked; if (this.InvokeRequired) { Invoke(new FillTextRtsp(UpdateRtsp), request); } else { textBox2.AppendText(string.Format(TestingFormat, request.ToString())); } } }
private void RTSPClient_OnResponse(RtspClient sender, RtspMessage request, RtspMessage response) { if (InvokeRequired) { MethodInvoker del = delegate { RTSPClient_OnResponse(sender, request, response); }; Invoke(del); } else { if (request != null && response != null) { //Disable keep alives if indicated //m_rtspClient.DisableKeepAliveRequest = checkBox1.Checked; RTSPMessagesTextBox.AppendText("RTSPClient_OnResponse (Request)" + Environment.NewLine); RTSPMessagesTextBox.AppendText("@" + request.Created.ToUniversalTime().ToString() + " - " + request.ToString() + Environment.NewLine); RTSPMessagesTextBox.AppendText("RTSPClient_OnResponse (Response)" + Environment.NewLine); RTSPMessagesTextBox.AppendText("@" + response.Created.ToUniversalTime().ToString() + " - " + response.ToString() + Environment.NewLine); } } }
void sender_OnResponse(RtspClient sender, RtspMessage request, RtspMessage response) { if (request != null && response != null) { //Disable keep alives if indicated Client.DisableKeepAliveRequest = checkBox1.Checked; if (this.InvokeRequired) { Invoke(new FillTextRtsp(UpdateRtsp), request); Invoke(new FillTextRtsp(UpdateRtsp), response); } else { textBox2.AppendText(string.Format(TestingFormat, request.ToString(), response.ToString())); } } }