Ejemplo n.º 1
0
        public override void OnApplyTemplate()
        {
            base.OnApplyTemplate();

            m_redColorSlider = GetTemplateChild(RedColorSliderName) as ColorSlider;
            m_greenColorSlider = GetTemplateChild(GreenColorSliderName) as ColorSlider;
            m_blueColorSlider = GetTemplateChild(BlueColorSliderName) as ColorSlider;
            m_alphaColorSlider = GetTemplateChild(AlphaColorSliderName) as ColorSlider;
            m_spectrumSlider = GetTemplateChild(SpectrumSliderName) as SpectrumSlider;
            m_hsvControl = GetTemplateChild(HsvControlName) as HsvControl;

            m_templateApplied = true;
            UpdateControlColors(SelectedColor);
        }
Ejemplo n.º 2
0
 private void SetColorSliderBackground(ColorSlider colorSlider, Color leftColor, Color rightColor)
 {
     if (colorSlider != null)
     {
         colorSlider.LeftColor = leftColor;
         colorSlider.RightColor = rightColor;
     }
 }