mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-21 20:24:59 +00:00
feature<TextDiffView>: supports line staging/unstaging in working copy diff view
This commit is contained in:
parent
91ef4e44a4
commit
671e46f8b3
10 changed files with 443 additions and 46 deletions
|
@ -54,7 +54,7 @@ namespace SourceGit.ViewModels {
|
|||
ProgressDescription = "Apply patch...";
|
||||
|
||||
return Task.Run(() => {
|
||||
var succ = new Commands.Apply(_repo.FullPath, _patchFile, _ignoreWhiteSpace, SelectedWhiteSpaceMode.Arg).Exec();
|
||||
var succ = new Commands.Apply(_repo.FullPath, _patchFile, _ignoreWhiteSpace, SelectedWhiteSpaceMode.Arg, null).Exec();
|
||||
CallUIThread(() => _repo.SetWatcherEnabled(true));
|
||||
return succ;
|
||||
});
|
||||
|
|
|
@ -5,6 +5,18 @@ using System.Threading.Tasks;
|
|||
|
||||
namespace SourceGit.ViewModels {
|
||||
public class DiffContext : ObservableObject {
|
||||
public string RepositoryPath {
|
||||
get => _repo;
|
||||
}
|
||||
|
||||
public Models.Change WorkingCopyChange {
|
||||
get => _option.WorkingCopyChange;
|
||||
}
|
||||
|
||||
public bool IsUnstaged {
|
||||
get => _option.IsUnstaged;
|
||||
}
|
||||
|
||||
public string FilePath {
|
||||
get => _option.Path;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue