public void RemoveInvalidUrlModel(string modelName, LivestreamerProcess proc) { // Telling user URL was invalid Invoke((MethodInvoker)(() => MessageBox.Show(this, "Unregistered model detected: " + modelName, "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation))); // Removing from listeners if (_manager.RemoveModel(modelName)) { // Removing from UI modelsBox.Invoke((MethodInvoker)(() => modelsBox.Items.Remove(modelName))); } }
public void RemoveInvalidUrlModel(string modelName) { // Telling user URL was invalid Log.Warn($"Invalid model: {modelName}"); Invoke((MethodInvoker)(() => MessageBox.Show(this, $"Unregistered model detected: {modelName}", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Exclamation))); // Removing from listeners if (_manager.RemoveModel(modelName)) { // Removing from UI models.RemoveModel(modelName); } }