void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) { switch (connectionId) { case 1: this.disconnect = ((System.Windows.Controls.Button)(target)); return; case 2: this.connect = ((System.Windows.Controls.Button)(target)); return; case 3: this.settings = ((System.Windows.Controls.Button)(target)); return; case 4: this.flightBoardView = ((FlightSimulator.Views.FlightBoard)(target)); return; case 5: this.commandCenterUCView = ((FlightSimulator.Views.CommandCenterUCView)(target)); return; } this._contentLoaded = true; }
public FlightBoardView() { InitializeComponent(); FlightBoardViewModel vm = new FlightBoardViewModel(); DataContext = vm; FlightBoard.setVM(vm); }
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) { switch (connectionId) { case 1: this.FlBoard = ((FlightSimulator.Views.FlightBoard)(target)); return; case 2: this.SettingControl = ((FlightSimulator.Views.Settings)(target)); return; case 3: #line 34 "..\..\MainWindow.xaml" ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.ConnectButton); #line default #line hidden return; case 4: this.settingButton = ((System.Windows.Controls.Primitives.ToggleButton)(target)); #line 38 "..\..\MainWindow.xaml" this.settingButton.Checked += new System.Windows.RoutedEventHandler(this.settingButton_Checked); #line default #line hidden return; case 5: this.JoyStickView = ((FlightSimulator.Views.Joystick)(target)); return; case 6: this.rudderSlider = ((System.Windows.Controls.Slider)(target)); return; case 7: this.throttleSlider = ((System.Windows.Controls.Slider)(target)); return; case 8: this.ClearText = ((System.Windows.Controls.Grid)(target)); return; case 9: this.OKCommands = ((System.Windows.Controls.Button)(target)); #line 127 "..\..\MainWindow.xaml" this.OKCommands.Click += new System.Windows.RoutedEventHandler(this.OKSendCommand); #line default #line hidden return; case 10: #line 128 "..\..\MainWindow.xaml" ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.ClearButton); #line default #line hidden return; case 11: this.TextBoxCommands = ((System.Windows.Controls.TextBox)(target)); #line 129 "..\..\MainWindow.xaml" this.TextBoxCommands.TextChanged += new System.Windows.Controls.TextChangedEventHandler(this.ClearTextBox_TextChanged); #line default #line hidden return; } this._contentLoaded = true; }