/// <summary> /// Get the colorscheme of a Control from a parent FormSkin. /// </summary> /// <param name="control">Control</param> /// <returns>Colors</returns> /// <exception cref="System.ArgumentNullException"></exception> public static NicolauColors GetColors(Control control) { if (control == null) { throw new ArgumentNullException(); } NicolauColors colors = new NicolauColors(); while (control != null && (control.GetType() != typeof(NicolauSkin))) { control = control.Parent; } if (control != null) { NicolauSkin skin = (NicolauSkin)control; colors.Nicolau = skin.NicolauColor; } return(colors); }
private void UpdateColors() { NicolauColors colors = Helpers.GetColors(this); _TrackColor = colors.Nicolau; }
private void UpdateColors() { NicolauColors colors = Helpers.GetColors(this); _ProgressColor = colors.Nicolau; }
private void UpdateColors() { NicolauColors colors = Helpers.GetColors(this); _SelectedColor = colors.Nicolau; }