private void destroyButton_Click(object sender, EventArgs e) { _replacer.ReplaceNextMessageBoxPosition(); if (MessageBox.Show(Resources.DestroyMessage, @"destroy", MessageBoxButtons.OKCancel, MessageBoxIcon.Warning) == DialogResult.OK) { var commandName = destroyButton.Text.ToLower(); _vagrantWrapper.ExecuteVagrantCommandAsync(VagrantFilePath, VagrantWrapper.ToCommand(commandName)); } }
private void statusButton_Click(object sender, EventArgs e) { var button = sender as Button; if (button != null) { var commandName = button.Text.ToLower(); _vagrantWrapper.ExecuteVagrantCommandAsync(VagrantFilePath, VagrantWrapper.ToCommand(commandName)); } }