本文整理汇总了C#中GitCommands.GitRevision类的典型用法代码示例。如果您正苦于以下问题:C# GitRevision类的具体用法?C# GitRevision怎么用?C# GitRevision使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
GitRevision类属于GitCommands命名空间,在下文中一共展示了GitRevision类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: BuildStatusMessageCellPainting
public static void BuildStatusMessageCellPainting(DataGridViewCellPaintingEventArgs e, GitRevision revision, Brush foreBrush, Font rowFont)
{
if (revision.BuildStatus != null)
{
Brush buildStatusForebrush = foreBrush;
switch (revision.BuildStatus.Status)
{
case BuildInfo.BuildStatus.Success:
buildStatusForebrush = Brushes.DarkGreen;
break;
case BuildInfo.BuildStatus.Failure:
buildStatusForebrush = Brushes.DarkRed;
break;
case BuildInfo.BuildStatus.InProgress:
buildStatusForebrush = Brushes.Blue;
break;
case BuildInfo.BuildStatus.Unstable:
buildStatusForebrush = Brushes.OrangeRed;
break;
case BuildInfo.BuildStatus.Stopped:
buildStatusForebrush = Brushes.Gray;
break;
}
var text = (string)e.FormattedValue;
e.Graphics.DrawString(text, rowFont, buildStatusForebrush, new PointF(e.CellBounds.Left, e.CellBounds.Top + 4));
}
}
开发者ID:neoandrew1000,项目名称:gitextensions,代码行数:29,代码来源:BuildInfoDrawingLogic.cs
示例2: BuildStatusImageColumnCellPainting
public static void BuildStatusImageColumnCellPainting(DataGridViewCellPaintingEventArgs e, GitRevision revision, Brush foreBrush, Font rowFont)
{
if (revision.BuildStatus != null)
{
Image buildStatusImage = null;
switch (revision.BuildStatus.Status)
{
case BuildInfo.BuildStatus.Success:
buildStatusImage = Resources.BuildSuccessful;
break;
case BuildInfo.BuildStatus.Failure:
buildStatusImage = Resources.BuildFailed;
break;
case BuildInfo.BuildStatus.Unknown:
buildStatusImage = Resources.BuildCancelled;
break;
case BuildInfo.BuildStatus.InProgress:
buildStatusImage = Resources.Icon_77;
break;
case BuildInfo.BuildStatus.Unstable:
buildStatusImage = Resources.bug;
break;
case BuildInfo.BuildStatus.Stopped:
buildStatusImage = Resources.BuildCancelled;
break;
}
if (buildStatusImage != null)
{
e.Graphics.DrawImage(buildStatusImage, new Rectangle(e.CellBounds.Left, e.CellBounds.Top + 4, 16, 16));
}
}
}
开发者ID:neoandrew1000,项目名称:gitextensions,代码行数:34,代码来源:BuildInfoDrawingLogic.cs
示例3: RevisionGrid
public RevisionGrid(GitRevision initialSelectedRevision)
{
_initialSelectedRevision = initialSelectedRevision;
syncContext = SynchronizationContext.Current;
base.InitLayout();
InitializeComponent(); Translate();
NormalFont = Revisions.Font;
HeadFont = new Font(NormalFont, FontStyle.Underline);
RefsFont = new Font(NormalFont, FontStyle.Bold);
Revisions.CellPainting += new DataGridViewCellPaintingEventHandler(Revisions_CellPainting);
Revisions.KeyDown += new KeyEventHandler(Revisions_KeyDown);
showRevisionGraphToolStripMenuItem.Checked = Settings.ShowRevisionGraph;
showAuthorDateToolStripMenuItem.Checked = Settings.ShowAuthorDate;
orderRevisionsByDateToolStripMenuItem.Checked = Settings.OrderRevisionByDate;
showRelativeDateToolStripMenuItem.Checked = Settings.RelativeDate;
BranchFilter = String.Empty;
SetShowBranches();
filter = "";
quickSearchString = "";
quickSearchTimer.Tick += new EventHandler(quickSearchTimer_Tick);
Revisions.Loading += new DvcsGraph.LoadingHandler(Revisions_Loading);
}
开发者ID:Gitulf,项目名称:gitextensions,代码行数:28,代码来源:RevisionGrid.cs
示例4: SetRevision
public void SetRevision(string revision)
{
Revision = new GitRevision();
Revision.Guid = revision;
Revision.ParentGuids = new string[]{revision + "^"};
SetRevision(Revision);
}
开发者ID:TwistedHope,项目名称:gitextensions,代码行数:7,代码来源:FormDiffSmall.cs
示例5: FormDiff
public FormDiff(GitUICommands aCommands, RevisionGrid revisionGrid, string baseCommitSha,
string headCommitSha, string baseCommitDisplayStr, string headCommitDisplayStr) : base(aCommands)
{
RevisionGrid = revisionGrid;
_baseCommitDisplayStr = baseCommitDisplayStr;
_headCommitDisplayStr = headCommitDisplayStr;
InitializeComponent();
Translate();
_toolTipControl.SetToolTip(btnAnotherBaseBranch, anotherBranchTooltip.Text);
_toolTipControl.SetToolTip(btnAnotherHeadBranch, anotherBranchTooltip.Text);
_toolTipControl.SetToolTip(btnAnotherBaseCommit, anotherCommitTooltip.Text);
_toolTipControl.SetToolTip(btnAnotherHeadCommit, anotherCommitTooltip.Text);
_toolTipControl.SetToolTip(btnSwap, btnSwapTooltip.Text);
if (!IsUICommandsInitialized)
{// UICommands is not initialized in translation unit test.
return;
}
_baseRevision = new GitRevision(Module, baseCommitSha);
_headRevision = new GitRevision(Module, headCommitSha);
_mergeBase = new GitRevision(Module, Module.GetMergeBase(_baseRevision.Guid, _headRevision.Guid));
lblBaseCommit.BackColor = AppSettings.DiffRemovedColor;
lblHeadCommit.BackColor = AppSettings.DiffAddedColor;
DiffFiles.SelectedIndexChanged += DiffFiles_SelectedIndexChanged;
DiffFiles.ContextMenuStrip = DiffContextMenu;
this.Load += (sender, args) => PopulateDiffFiles();
}
开发者ID:vbjay,项目名称:gitextensions,代码行数:34,代码来源:FormDiff.cs
示例6: FormDiff
public FormDiff(GitRevision revision)
{
InitializeComponent();
EditorOptions.SetSyntax(DiffText, "output.cs");
RevisionGrid.SetSelectedRevision( revision);
}
开发者ID:arBmind,项目名称:gitextensions,代码行数:7,代码来源:FormDiff.cs
示例7: FormFileHistory
public FormFileHistory(string fileName, GitRevision revision, bool filterByRevision)
: base(true)
{
InitializeComponent();
syncContext = SynchronizationContext.Current;
filterBranchHelper = new FilterBranchHelper(toolStripBranches, toolStripDropDownButton2, FileChanges);
filterRevisionsHelper = new FilterRevisionsHelper(toolStripTextBoxFilter, toolStripDropDownButton1, FileChanges, toolStripLabel2, this);
FileChanges.SetInitialRevision(revision);
Translate();
FileName = fileName;
Diff.ExtraDiffArgumentsChanged += DiffExtraDiffArgumentsChanged;
FileChanges.SelectionChanged += FileChangesSelectionChanged;
FileChanges.DisableContextMenu();
followFileHistoryToolStripMenuItem.Checked = Settings.FollowRenamesInFileHistory;
fullHistoryToolStripMenuItem.Checked = Settings.FullHistoryInFileHistory;
loadHistoryOnShowToolStripMenuItem.Checked = Settings.LoadFileHistoryOnShow;
loadBlameOnShowToolStripMenuItem.Checked = Settings.LoadBlameOnShow;
if (filterByRevision && revision != null && revision.Guid != null)
filterBranchHelper.SetBranchFilter(revision.Guid, false);
}
开发者ID:vgravade,项目名称:gitextensions,代码行数:27,代码来源:FormFileHistory.cs
示例8: SetRevision
public void SetRevision(string revision)
{
Revision = new GitRevision();
Revision.Guid = revision;
Revision.ParentGuids.Add(revision + "^");
SetRevision(Revision);
}
开发者ID:jorn,项目名称:gitextensions,代码行数:7,代码来源:FormDiffSmall.cs
示例9: FormDiff
public FormDiff(GitRevision revision)
{
InitializeComponent();
Translate();
RevisionGrid.SetSelectedRevision(revision);
}
开发者ID:helmus,项目名称:gitextensions,代码行数:7,代码来源:FormDiff.cs
示例10: FormCherryPickCommitSmall
public FormCherryPickCommitSmall(GitRevision revision)
{
Revision = revision;
InitializeComponent();
Translate();
}
开发者ID:edvillan15,项目名称:gitextensions,代码行数:7,代码来源:FormCherryPickCommitSmall.cs
示例11: AddPoint
public LanePoint AddPoint(Lane lane, GitRevision revision)
{
LanePoint point = lane.AddPoint(lane, Points.Count);
Points.Add(point);
point.Revision = revision;
return point;
}
开发者ID:OldPaladin,项目名称:gitextensions,代码行数:7,代码来源:LaneGraph.cs
示例12: FormResetCurrentBranch
public FormResetCurrentBranch(GitUICommands aCommands, GitRevision Revision)
: base(aCommands)
{
this.Revision = Revision;
InitializeComponent(); Translate();
}
开发者ID:neoandrew1000,项目名称:gitextensions,代码行数:7,代码来源:FormResetCurrentBranch.cs
示例13: FormRevertCommitSmall
public FormRevertCommitSmall(GitUICommands aCommands, GitRevision Revision)
: base(aCommands)
{
this.Revision = Revision;
InitializeComponent(); Translate();
}
开发者ID:rudisherry666,项目名称:gitextensions,代码行数:7,代码来源:FormRevertCommitSmall.cs
示例14: SetRevision
public void SetRevision(GitRevision revision)
{
Revision = revision;
DiffFiles.GitItemStatuses = null;
DiffFiles.GitItemStatuses = Settings.Module.GetDiffFiles(revision.Guid, revision.Guid + "^");
commitInfo.SetRevision(revision.Guid);
}
开发者ID:hogelog,项目名称:gitextensions,代码行数:8,代码来源:FormDiffSmall.cs
示例15: SetRevision
public void SetRevision(GitRevision revision)
{
Revision = revision;
DiffFiles.DataSource = null;
DiffFiles.DisplayMember = "FileNameB";
DiffFiles.DataSource = GitCommands.GitCommands.GetDiffFiles(revision.Guid, revision.ParentGuids[0]);
}
开发者ID:arBmind,项目名称:gitextensions,代码行数:8,代码来源:FormDiffSmall.cs
示例16: FormCherryPick
public FormCherryPick(GitUICommands aCommands, GitRevision revision)
: base(aCommands)
{
Revision = revision;
InitializeComponent();
Translate();
}
开发者ID:Copro,项目名称:gitextensions,代码行数:8,代码来源:FormCherryPick.cs
示例17: SetRevision
public void SetRevision(GitRevision revision)
{
Revision = revision;
DiffFiles.GitItemStatuses = null;
DiffFiles.GitItemStatuses = GitCommandHelpers.GetDiffFiles(revision.Guid + "^", revision.Guid);
commitInfo.SetRevision(revision.Guid);
}
开发者ID:parsifal1818,项目名称:gitextensions,代码行数:8,代码来源:FormDiffSmall.cs
示例18: FormTagSmall
public FormTagSmall(GitRevision revision)
{
InitializeComponent();
Translate();
tagMessage.MistakeFont = new Font(SystemFonts.MessageBoxFont, FontStyle.Underline);
this.revision = revision;
}
开发者ID:ksukhonosenko,项目名称:gitextensions,代码行数:8,代码来源:FormTagSmall.cs
示例19: FormResetCurrentBranch
public FormResetCurrentBranch(GitUICommands aCommands, GitRevision Revision)
: base(aCommands)
{
this.Revision = Revision;
InitializeComponent(); Translate();
this.checkNoAsk.Checked = false; // default
}
开发者ID:akrisiun,项目名称:gitextensions,代码行数:8,代码来源:FormResetCurrentBranch.cs
示例20: GitRefListsForRevision
public GitRefListsForRevision(GitRevision revision)
{
_allBranches = revision.Refs.Where(h => !h.IsTag && (h.IsHead || h.IsRemote)).ToArray();
_localBranches = _allBranches.Where(b => !b.IsRemote).ToArray();
_branchesWithNoIdenticalRemotes = _allBranches.Where(
b => !b.IsRemote || !_localBranches.Any(lb => lb.TrackingRemote == b.Remote && lb.MergeWith == b.LocalName)).ToArray();
_tags = revision.Refs.Where(h => h.IsTag).ToArray();
}
开发者ID:Carbenium,项目名称:gitextensions,代码行数:9,代码来源:GitRefListsForRevision.cs
注:本文中的GitCommands.GitRevision类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论