public CheckBlocksWindow(CheckBlocksWindowViewModel viewModel) { this.DataContext = viewModel; viewModel.CloseEvent += (sender, e) => this.Close(); InitializeComponent(); }
public void Show(CheckBlocksWindowViewModel viewModel) { var window = new CheckBlocksWindow(viewModel); window.Owner = App.Current.MainWindow; window.Show(); }
public CheckBlocksWindow(CheckBlocksWindowViewModel viewModel) { this.DataContext = viewModel; viewModel.CloseEvent += (sender, e) => this.Close(); InitializeComponent(); this.MouseLeftButtonDown += (sender, e) => this.DragMove(); }
private void CheckBlocks() { if (_isRunning_CheckBlocks) { return; } _isRunning_CheckBlocks = true; var viewModel = new CheckBlocksWindowViewModel(_amoebaInterfaceManager); viewModel.CloseEvent += (sender, e) => _isRunning_CheckBlocks = false; _dialogService.Show(viewModel); }