Ejemplo n.º 1
0
 private void buttonGotoCommit_Click(object sender, EventArgs e)
 {
     using (var formGoToCommit = new FormGoToCommit(UICommands))
     {
         if (formGoToCommit.ShowDialog(this) == DialogResult.OK)
         {
             string revisionGuid = formGoToCommit.ValidateAndGetSelectedRevision();
             if (!string.IsNullOrEmpty(revisionGuid))
             {
                 revisionGrid.SetSelectedRevision(new GitRevision(Module, revisionGuid));
             }
             else
             {
                 MessageBox.Show(this, _noRevisionFoundError.Text);
             }
         }
     }
 }
Ejemplo n.º 2
0
        public void GotoCommitExcecute()
        {
            using (FormGoToCommit formGoToCommit = new FormGoToCommit(_revisionGrid.UICommands))
            {
                if (formGoToCommit.ShowDialog(_revisionGrid) != DialogResult.OK)
                {
                    return;
                }

                string revisionGuid = formGoToCommit.ValidateAndGetSelectedRevision();
                if (!string.IsNullOrEmpty(revisionGuid))
                {
                    _revisionGrid.SetSelectedRevision(new GitRevision(_revisionGrid.Module, revisionGuid));
                }
                else
                {
                    MessageBox.Show(_revisionGrid, _noRevisionFoundError.Text);
                }
            }
        }
        public void GotoCommitExcecute()
        {
            using (FormGoToCommit formGoToCommit = new FormGoToCommit(_revisionGrid.UICommands))
            {
                if (formGoToCommit.ShowDialog(_revisionGrid) != DialogResult.OK)
                {
                    return;
                }

                var revisionGuid = formGoToCommit.ValidateAndGetSelectedRevision();
                if (revisionGuid != null)
                {
                    _revisionGrid.SetSelectedRevision(new GitRevision(revisionGuid.ToString()));
                }
                else
                {
                    MessageBox.Show(_revisionGrid, _noRevisionFoundError.Text);
                }
            }
        }
Ejemplo n.º 4
0
        public void GotoCommitExecute()
        {
            using (var formGoToCommit = new FormGoToCommit(_revisionGrid.UICommands))
            {
                if (formGoToCommit.ShowDialog(_revisionGrid) != DialogResult.OK)
                {
                    return;
                }

                var objectId = formGoToCommit.ValidateAndGetSelectedRevision();

                if (objectId != null)
                {
                    _revisionGrid.SetSelectedRevision(new GitRevision(objectId));
                }
                else
                {
                    MessageBox.Show(_revisionGrid, _noRevisionFoundError.Text, Strings.Error, MessageBoxButtons.OK, MessageBoxIcon.Error);
                }
            }
        }