mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-21 04:04:59 +00:00
feature: supports custom actions (#638)
Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
parent
7c5de7e48c
commit
a36058ec51
17 changed files with 478 additions and 2 deletions
|
@ -100,6 +100,12 @@ namespace SourceGit.Models
|
|||
set;
|
||||
} = new AvaloniaList<IssueTrackerRule>();
|
||||
|
||||
public AvaloniaList<CustomAction> CustomActions
|
||||
{
|
||||
get;
|
||||
set;
|
||||
} = new AvaloniaList<CustomAction>();
|
||||
|
||||
public bool EnableAutoFetch
|
||||
{
|
||||
get;
|
||||
|
@ -230,5 +236,22 @@ namespace SourceGit.Models
|
|||
if (rule != null)
|
||||
IssueTrackerRules.Remove(rule);
|
||||
}
|
||||
|
||||
public CustomAction AddNewCustomAction()
|
||||
{
|
||||
var act = new CustomAction()
|
||||
{
|
||||
Name = "Unnamed Custom Action",
|
||||
};
|
||||
|
||||
CustomActions.Add(act);
|
||||
return act;
|
||||
}
|
||||
|
||||
public void RemoveCustomAction(CustomAction act)
|
||||
{
|
||||
if (act != null)
|
||||
CustomActions.Remove(act);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue