public void ShowSettings() { GuagesSettingViewModel settingsViewModel = new GuagesSettingViewModel(this.ViewModel, this._viewerWindow); GuagesSettingView window = new GuagesSettingView(settingsViewModel, this._viewerWindow); window.Owner = Application.Current.MainWindow; window.WindowStartupLocation = WindowStartupLocation.CenterOwner; window.ShowDialog(); }
public GuagesSettingView(GuagesSettingViewModel viewModel, GuagesView view) { InitializeComponent(); this.DataContext = viewModel; this._viewModel = viewModel; this._view = view; GaugeTypeList(); this.cmboGaugeType.Text = _viewModel._viewerModel.Parameters.GuageType.ToString(); this.txtHigh.Text = _viewModel._viewerModel.Parameters.High.ToString(); this.ChkReverse.IsChecked = _viewModel._viewerModel.Parameters.Reverse; // this._viewModel = viewModel; }