feature<AutoFetch>: finish auto fetch remotes

This commit is contained in:
leo 2024-02-18 16:26:07 +08:00
parent b40ca42d73
commit 05c9d9be5b
6 changed files with 88 additions and 6 deletions

View file

@ -112,8 +112,13 @@ namespace SourceGit.ViewModels {
}
public bool GitAutoFetch {
get => _gitAutoFetch;
set => SetProperty(ref _gitAutoFetch, value);
get => Commands.AutoFetch.IsEnabled;
set {
if (Commands.AutoFetch.IsEnabled != value) {
Commands.AutoFetch.IsEnabled = value;
OnPropertyChanged(nameof(GitAutoFetch));
}
}
}
public int ExternalMergeToolType {
@ -242,7 +247,6 @@ namespace SourceGit.ViewModels {
private Models.ChangeViewMode _commitChangeViewMode = Models.ChangeViewMode.List;
private string _gitDefaultCloneDir = string.Empty;
private bool _gitAutoFetch = false;
private int _externalMergeToolType = 0;
private string _externalMergeToolPath = string.Empty;