private void menuPacketDump_Click(object sender, EventArgs e) { if (PacketDumpFileDialog.ShowDialog() == DialogResult.OK) { StatusBar.Text = "Packet dump in progress. Please wait..."; Log("Packets dump in progress..."); DisableAllControls(); Application.DoEvents(); if (StreamProcessor.DumpPackets(PacketDumpFileDialog.FileName, Properties.Settings.Default.DumpTimeStamps)) { StatusBar.Text = "Packets dumped successfully."; Log("Packets dumped successfully."); } else { StatusBar.Text = "Packet dump failed."; Log("Packet dump failed."); } EnableAllControls(); } }
private void menuDumpAAs_Click(object sender, EventArgs e) { if (PacketDumpFileDialog.ShowDialog() != DialogResult.OK) { return; } Log("AA dump in progress..."); DisableAllControls(); var bw = new BackgroundWorker(); bw.DoWork += DumpAAs; bw.RunWorkerCompleted += EnableAllControlsOnCompletion; bw.RunWorkerAsync(); }
private void menuPacketDump_Click(object sender, EventArgs e) { if (PacketDumpFileDialog.ShowDialog() != DialogResult.OK) { return; } SetStatus("Packet dump in progress. Please wait..."); Log("Packets dump in progress..."); DisableAllControls(); Application.DoEvents(); var bw = new BackgroundWorker(); bw.DoWork += DumpPackets; bw.RunWorkerCompleted += EnableAllControlsOnCompletion; bw.RunWorkerAsync(); }
private void menuDumpAAs_Click(object sender, EventArgs e) { if (PacketDumpFileDialog.ShowDialog() == DialogResult.OK) { Log("AA dump in progress..."); DisableAllControls(); if (StreamProcessor.DumpAAs(PacketDumpFileDialog.FileName)) { StatusBar.Text = "AAs dumped successfully."; Log("AAs dumped successfully."); } else { StatusBar.Text = "AA dumped failed."; Log("AA dump failed."); } EnableAllControls(); } }