private static void OnSaturationChanged(DependencyObject o, DependencyPropertyChangedEventArgs e) { FrmColorPicker frmColorPicker = o as FrmColorPicker; if (frmColorPicker != null) { frmColorPicker.OnSaturationChanged((double)e.OldValue, (double)e.NewValue); } }
private static void SetLightFrame(Light light, FrmColorPicker colorPicker, int frameIndex) { if (light == null) { return; } while (frameIndex >= light.SequenceData.Count) { light.SequenceData.Add(new LightSequenceData()); } light.SequenceData[frameIndex].Hue = (int)colorPicker.Hue; light.SequenceData[frameIndex].Saturation = (int)colorPicker.Saturation; light.SequenceData[frameIndex].Lightness = (int)colorPicker.Lightness; }
private void SetColorPicker(LightSequenceData lightSequenceData, FrmColorPicker colorPicker) { settingColorInternally = true; try { colorPicker.Hue = (int)lightSequenceData.Hue; colorPicker.Saturation = (int)lightSequenceData.Saturation; colorPicker.Lightness = (int)lightSequenceData.Lightness; } finally { settingColorInternally = false; } }
private void SetLightFrame(Light light, FrmColorPicker colorPicker) { SetLightFrame(light, colorPicker, FrameIndex); }