示例#1
0
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:

            #line 45 "..\..\..\Views\MainWindow.xaml"
                ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.SelectedTabChange);

            #line default
            #line hidden
                return;

            case 2:

            #line 46 "..\..\..\Views\MainWindow.xaml"
                ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.SelectedTabChange);

            #line default
            #line hidden
                return;

            case 3:
                this.GridCursor = ((System.Windows.Controls.Grid)(target));
                return;

            case 4:
                this.ReportFormView = ((MvvmWpfApp.Views.NewReportFormView)(target));
                return;
            }
            this._contentLoaded = true;
        }
        private void ListViewMenu_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            UserControl usc = null;

            GridMain.Children.Clear();
            mainTitle.Text = "Detecting Rocket Hits";
            switch (((ListViewItem)((ListView)sender).SelectedItem).Name)
            {
            case "ItemHome":
                usc = new MapView();
                GridMain.Children.Add(usc);
                mainTitle.Text = "View Map and Hits";
                break;

            case "ItemReport":
                usc = new NewReportFormView();
                GridMain.Children.Add(usc);
                mainTitle.Text = "Add New Report";
                break;

            case "ItemAnalysis":
                usc = new ChartView();
                GridMain.Children.Add(usc);
                mainTitle.Text = "Analysis";
                break;

            case "ItemEvaluate":
                usc = new EvaluateView();
                GridMain.Children.Add(usc);
                mainTitle.Text = "Evaluate k-Means Performance";
                break;

            case "ItemUpdate":
                usc = new UploadPhotoView();
                GridMain.Children.Add(usc);
                mainTitle.Text = "Upload Photo for Real Location";
                break;

            default:
                break;
            }
        }
示例#3
0
        private void ListViewMenu_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            UserControl usc = null;

            GridMain.Children.Clear();

            switch (((ListViewItem)((ListView)sender).SelectedItem).Name)
            {
            case "ItemHome":
                usc = new UserControlHome();
                GridMain.Children.Add(usc);
                break;

            case "ItemCreate":
                usc = new NewReportFormView();
                GridMain.Children.Add(usc);
                break;

            default:
                break;
            }
        }
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.FlipViewTest = ((MahApps.Metro.Controls.FlipView)(target));

            #line 62 "..\..\..\Views\MainWindow.xaml"
                this.FlipViewTest.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.FlipView_SelectionChanged);

            #line default
            #line hidden
                return;

            case 2:

            #line 89 "..\..\..\Views\MainWindow.xaml"
                ((MahApps.Metro.Controls.Tile)(target)).Click += new System.Windows.RoutedEventHandler(this.Map_Click);

            #line default
            #line hidden
                return;

            case 3:

            #line 95 "..\..\..\Views\MainWindow.xaml"
                ((MahApps.Metro.Controls.Tile)(target)).Click += new System.Windows.RoutedEventHandler(this.Stat_Click);

            #line default
            #line hidden
                return;

            case 4:

            #line 100 "..\..\..\Views\MainWindow.xaml"
                ((MahApps.Metro.Controls.Tile)(target)).Click += new System.Windows.RoutedEventHandler(this.pic_Click);

            #line default
            #line hidden
                return;

            case 5:

            #line 105 "..\..\..\Views\MainWindow.xaml"
                ((MahApps.Metro.Controls.Tile)(target)).Click += new System.Windows.RoutedEventHandler(this.About_Click);

            #line default
            #line hidden
                return;

            case 6:
                this.homeBtn = ((System.Windows.Controls.Button)(target));

            #line 118 "..\..\..\Views\MainWindow.xaml"
                this.homeBtn.Click += new System.Windows.RoutedEventHandler(this.HomeBtn_Click);

            #line default
            #line hidden
                return;

            case 7:
                this.ReportFormView = ((MvvmWpfApp.Views.NewReportFormView)(target));
                return;

            case 8:
                this.MapView = ((MvvmWpfApp.MapView)(target));
                return;

            case 9:

            #line 170 "..\..\..\Views\MainWindow.xaml"
                ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.HomeBtn_Click);

            #line default
            #line hidden
                return;

            case 10:
                this.ChooseExplosionsView = ((MvvmWpfApp.Views.ChooseExplosionsView)(target));
                return;

            case 11:
                this.GraphView = ((MvvmWpfApp.GraphView)(target));
                return;

            case 12:

            #line 194 "..\..\..\Views\MainWindow.xaml"
                ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.HomeBtn_Click);

            #line default
            #line hidden
                return;

            case 13:

            #line 219 "..\..\..\Views\MainWindow.xaml"
                ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.HomeBtn_Click);

            #line default
            #line hidden
                return;
            }
            this._contentLoaded = true;
        }