예제 #1
0
 internal void CaptureFinished()
 {
     CapturePreviews.DecrementCaptures();
     finishedCapture.Background = Brushes.Green;
     RunningLabel.Content       = "Capture Process Finished";
     running = false;
 }
예제 #2
0
        // Capture starting and finished handlers
        internal void CaptureFinished()
        {
            CapturePreviews.DecrementCaptures();
            finishedCapture.Background = Brushes.Green;
            RunningLabel.Content       = "Capture Process Finished";
            running = false;

            StopButton.Visibility = Visibility.Hidden;

            if (!aw.getPicker().countAnalysis)
            {
                file.BuildAndSave();
            }
        }
예제 #3
0
        // UI Closing handling

        private void CaptureWindow_Closing(object sender, CancelEventArgs e)
        {
            if (MainWindow.killRequest)
            {
                newCaptureThread.Abort();
                e.Cancel = false;
                aw.Close();
            }
            else
            {
                if (running)
                {
                    string msg = "Kill capture process?";

                    MessageBoxResult res =
                        MessageBox.Show(
                            msg,
                            "Closing Dialog",
                            MessageBoxButton.YesNo,
                            MessageBoxImage.Warning);

                    if (res == MessageBoxResult.No)
                    {
                        e.Cancel = true;
                        this.Hide();
                    }
                    else
                    {
                        e.Cancel = false;
                        CapturePreviews.DecrementCaptures();
                        newCaptureThread.Abort();
                        cp.EraseFinishedCapture(Int32.Parse(this.Uid));
                        aw.requestClosing();
                        aw.Close();
                    }
                }
                else
                {
                    cp.EraseFinishedCapture(Int32.Parse(this.Uid));
                    e.Cancel = false;
                    aw.requestClosing();
                    aw.Close();
                }
                if (playing)
                {
                    playThread.Abort();
                }
            }
        }