private static void CompleteAndClose(AddPackageRepositoryWindow window)
 {
     RemoteRepositoryEditViewModel vm = (RemoteRepositoryEditViewModel)window.DataContext;
     vm.CompleteCommand.Execute(vm);
     window.Close();
 }
        private static bool CanComplete(AddPackageRepositoryWindow window)
        {
            if (window == null)
            {
                return false;
            }

            RemoteRepositoryEditViewModel vm = (RemoteRepositoryEditViewModel)window.DataContext;
            return vm.CompleteCommand.CanExecute(vm);
        }