private void RefreshCommands() { InstallCommand.RaiseCanExecuteChanged(); UninstallCommand.RaiseCanExecuteChanged(); StartCommand.RaiseCanExecuteChanged(); StopCommand.RaiseCanExecuteChanged(); RaisePropertyChanged("ServiceStatus"); RaisePropertyChanged("IsWorking"); }
private void DetectInstalledPackage() { if (Configurator.IsApplicationInstalled(Settings.ApplicationName)) { UninstallEnabled = true; view.Dispatcher.Invoke(() => { UninstallCommand?.RaiseCanExecuteChanged(); }); } else { InstallEnabled = true; view.Dispatcher.Invoke(() => { InstallCommand?.RaiseCanExecuteChanged(); }); } }