/// <summary> /// Describe (view) selected changelist /// </summary> private void MenuDescribeClick(object sender, EventArgs e) { FormShowChangelist.DriveChangelistFromListViewEx(ref listRev); }
/// <summary> /// Describe (view) selected changelist /// </summary> private void MenuDescribeClick(object sender, EventArgs e) { // Get the SHA associated with the selected item on the log list ListView li = listRev; if (li.SelectedIndices.Count != 1) return; int index = li.SelectedIndices[0]; FormShowChangelist form = new FormShowChangelist(); DialogResult dlg; do { li.Items[index].Selected = true; string sha = li.Items[index].Tag.ToString(); form.LoadChangelist(sha); dlg = form.ShowDialog(); // Using the "Yes" value to load a next commit if (dlg == DialogResult.Yes && index > 0) index--; // Using the "No" value to load a previous commit if (dlg == DialogResult.No && index < li.Items.Count - 1) index++; } while (dlg != DialogResult.Cancel); }