static void Disconnect() { waveIn.DataAvailable -= waveIn_DataAvailable; waveIn.StopRecording(); udpSender.Close(); waveIn.Dispose(); selectedCodec.Dispose(); }
public void Disconnect() { if (connected) { connected = false; //audioSender.Dispose(); // a bit naughty but we have designed the codecs to support multiple calls to Dispose, // recreating their resources if Encode/Decode called again selectedCodec.Dispose(); } }
private void Disconnect() { if (connected) { connected = false; player.Dispose(); audioSender.Dispose(); selectedCodec.Dispose(); //new NetworkChatPanel(); saveIpPort(); //System.Windows.Forms.Application.Restart(); } }
private void Disconnect() { if (connected) { connected = false; waveIn.DataAvailable -= waveIn_DataAvailable; waveIn.StopRecording(); waveOut.Stop(); udpSender.Close(); udpListener.Close(); waveIn.Dispose(); waveOut.Dispose(); // a bit naughty but we have designed the codecs to support multiple calls to Dispose, // recreating their resources if Encode/Decode called again selectedCodec.Dispose(); } }
static void Disconnect() { udpListener.Close(); waveOut.Dispose(); selectedCodec.Dispose(); }