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
|
@ -18,16 +18,19 @@ namespace SourceGit.Models {
|
|||
public class TextDiffLine {
|
||||
public TextDiffLineType Type { get; set; } = TextDiffLineType.None;
|
||||
public string Content { get; set; } = "";
|
||||
public string OldLine { get; set; } = "";
|
||||
public string NewLine { get; set; } = "";
|
||||
public int OldLineNumber { get; set; } = 0;
|
||||
public int NewLineNumber { get; set; } = 0;
|
||||
public List<TextInlineRange> Highlights { get; set; } = new List<TextInlineRange>();
|
||||
|
||||
public string OldLine => OldLineNumber == 0 ? string.Empty : OldLineNumber.ToString();
|
||||
public string NewLine => NewLineNumber == 0 ? string.Empty : NewLineNumber.ToString();
|
||||
|
||||
public TextDiffLine() { }
|
||||
public TextDiffLine(TextDiffLineType type, string content, string oldLine, string newLine) {
|
||||
public TextDiffLine(TextDiffLineType type, string content, int oldLine, int newLine) {
|
||||
Type = type;
|
||||
Content = content;
|
||||
OldLine = oldLine;
|
||||
NewLine = newLine;
|
||||
OldLineNumber = oldLine;
|
||||
NewLineNumber = newLine;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue