/// <summary> /// Raises the <see cref="E:CommandEntering" /> event. /// </summary> /// <param name="e">The <see cref="BaseShellConsoleCommandEnteringEventArgs"/> instance containing the event data.</param> protected virtual void OnCommandEntering(BaseShellConsoleCommandEnteringEventArgs e) { if (CommandEntering != null) { CommandEntering(this, e); } }
/// <summary> /// Handles the TextChanged event of the txtInput control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param> private void txtInput_TextChanged(object sender, EventArgs e) { // Fire the CommandEntering event first BaseShellConsoleCommandEnteringEventArgs commandEnteringArgs = new BaseShellConsoleCommandEnteringEventArgs(txtInput.Text); OnCommandEntering(commandEnteringArgs); }