private void OnColorChoose(object sender, RoutedEventArgs e) { var button = sender as Button; if (sender == null) { return; } ColorChoose?.Invoke(button.Background); }
public void SetCurrentColorMode(string colorMode) { switch (colorMode.ToLower()) { case "grad": this.currentColorChoose = ColorChoose.Grad; break; case "red": this.currentColorChoose = ColorChoose.Red; break; case "blue": this.currentColorChoose = ColorChoose.Blue; break; } }