예제 #1
0
        void reader_OnStreamFinished(object sender, StreamFinishedEventArgs e)
        {
            if (_videoFile != null)
            {
                _videoFile.Flush();
                _videoFile.Close();
            }

            var a = new Action(() =>
            {
                lblStatus.Text = e.FoundDiscovery
                    ? "Finished."
                    : "No protocol discovery found. Some parts of capture are missing.";
                SetControls(true);
            });

            if (statusStrip1.InvokeRequired)
            {
                statusStrip1.Invoke(a);
            }
            else
            {
                a();
            }
        }
예제 #2
0
        void reader_OnStreamFinished(object sender, StreamFinishedEventArgs e)
        {
            if (_videoFile != null)
            {
                _videoFile.Flush();
                _videoFile.Close();
            }

            var a = new Action(() =>
            {
                lblStatus.Text = e.FoundDiscovery
                    ? "Finished."
                    : "No protocol discovery found. Some parts of capture are missing.";
                SetControls(true);
            });

            if (statusStrip1.InvokeRequired)
                statusStrip1.Invoke(a);
            else
                a();
        }