public void Execute(object parameter) { var connManagerWindow = new ConnectionManagerWindow(); connManagerWindow.WindowStartupLocation = System.Windows.WindowStartupLocation.CenterScreen; connManagerWindow.ShowDialog(); }
Task ICommandHandler <NewConnectionCommandDefinition> .Run(Command command) { var connManagerWindow = new ConnectionManagerWindow(); connManagerWindow.WindowStartupLocation = System.Windows.WindowStartupLocation.CenterScreen; connManagerWindow.ShowDialog(); return(TaskUtility.Completed); }
private void ShowConnectionManager() { Dictionary <string, IConnectivityTester> connector = new Dictionary <string, IConnectivityTester>(); connector.Add("Sql Server", new ConnectivityTester()); connector.Add("MySQL", new Models.MySql.ConnectivityTester()); var viewModel = new ConnectionManagerVM(new ConnectionManagerModel(), connector); viewModel.OnShowSchemaBrowserWindow += OnShowSchemaBrowserWindow; viewModel.OnShowQueryWindow += OnShowQueryWindow; var window = new ConnectionManagerWindow(viewModel); window.Show(); }