Пример #1
0
        //returns a given control on this form provided its name
        public Control GetControl(MainWindowControls name)
        {
            switch (name)
            {
            case MainWindowControls.time_elapsed:
                return(time_elapsed_label);

            case MainWindowControls.total_time:
                return(total_time_label);

            case MainWindowControls.review_image_box:
                return(review_footage_image_box);

            case MainWindowControls.live_stream_image_box1:
                return(imageBox1);

            case MainWindowControls.live_stream_image_box2:
                return(imageBox2);

            case MainWindowControls.live_stream_image_box3:
                return(imageBox3);

            case MainWindowControls.live_stream_image_box4:
                return(imageBox4);

            case MainWindowControls.review_footage_panel:
                return(panel_for_detected_faces);

            case MainWindowControls.live_stream_panel:
                return(live_stream_recognition_panel);

            case MainWindowControls.spining_progress_review:
                return(spining_progress_review);
            }
            return(null);
        }
Пример #2
0
        //returns a given control on this form provided its name
        public Control GetControl(MainWindowControls name)
        {
            switch (name)
            {
                case MainWindowControls.time_elapsed:
                    return time_elapsed_label;

                case MainWindowControls.total_time:
                    return total_time_label;

                case MainWindowControls.review_image_box:
                    return review_footage_image_box;

                case MainWindowControls.live_stream_image_box1:
                    return imageBox1;

                case MainWindowControls.live_stream_image_box2:
                    return imageBox2;

                case MainWindowControls.live_stream_image_box3:
                    return imageBox3;

                case MainWindowControls.live_stream_image_box4:
                    return imageBox4;

                case MainWindowControls.review_footage_panel:
                    return panel_for_detected_faces;

                case MainWindowControls.live_stream_panel:
                    return live_stream_recognition_panel;

                case MainWindowControls.spining_progress_review:
                    return spining_progress_review;

            }
            return null;
        }
 /// <summary>
 /// Main Window loaded event. Fills window with UserControl.
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 public void OnMainWindowLoaded(object sender, RoutedEventArgs e)
 {
     MainWindowControls.Add(new WorkplanListView());
 }