/// <summary> /// Handles the Click event of the getLastVersionMenuItem control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param> private void getLastVersionMenuItem_Click(object sender, EventArgs e) { TreeNode node = _treeCtrl.SelectedNode; ComponentModelMetadata metaData = GetSelectedData(); GetLastVersionCommand command = new GetLastVersionCommand(metaData, true); command.Exec(); if (node != null) { node.EnsureVisible(); } }
protected void OnStatusGetLastVersion(object sender, EventArgs e) { MenuCommand cmd = sender as MenuCommand; if (this.CurrentDocView.PrimarySelection != null) { GetLastVersionCommand command = new GetLastVersionCommand(SingleSelection); cmd.Visible = command.Visible(); cmd.Enabled = command.Enabled; return; } cmd.Enabled = cmd.Visible = false; }
protected void OnGetLastVersion(object sender, EventArgs e) { GetLastVersionCommand command = new GetLastVersionCommand(SingleSelection); command.Exec(); }