/// <summary>
        /// Set the specified style.
        /// </summary>
        /// <param name="styleColorPicker">Style for the ColorPicker.</param>
        /// <param name="style">Style data.</param>
        public virtual void SetStyle(StyleColorPicker styleColorPicker, Style style)
        {
            styleColorPicker.PaletteBorder.ApplyTo(image.transform.parent.GetComponent <Image>());

            if (imageCursor != null)
            {
                styleColorPicker.PaletteCursor.ApplyTo(imageCursor.GetComponent <Image>());
            }
        }
Esempio n. 2
0
 /// <summary>
 /// Set the specified style.
 /// </summary>
 /// <param name="styleColorPicker">Style for the ColorPicker.</param>
 /// <param name="style">Style data.</param>
 public override void SetStyle(StyleColorPicker styleColorPicker, Style style)
 {
     if (InputHex != null)
     {
         styleColorPicker.HexInputBackground.ApplyTo(InputHex);
         styleColorPicker.HexInputText.ApplyTo(InputHex.textComponent.gameObject);
         if (InputHex.placeholder != null)
         {
             styleColorPicker.HexInputPlaceholder.ApplyTo(InputHex.placeholder.gameObject);
         }
     }
 }
        /// <summary>
        /// Set specified style.
        /// </summary>
        /// <param name="styleColorPicker">Style for the ColorPicker.</param>
        /// <param name="style">Full style data.</param>
        public virtual void SetStyle(StyleColorPicker styleColorPicker, Style style)
        {
            if ((aSlider != null) && (aSlider.handleRect != null))
            {
                var handle_style = Utilites.IsHorizontal(aSlider)
                                        ? styleColorPicker.SliderVerticalHandle
                                        : styleColorPicker.SliderHorizontalHandle;
                handle_style.ApplyTo(aSlider.handleRect.GetComponent <Image>());
            }

            if (aInput != null)
            {
                aInput.SetStyle(styleColorPicker.InputSpinner, style);
            }
        }
        /// <summary>
        /// Set the specified style.
        /// </summary>
        /// <param name="styleColorPicker">Style for the ColorPicker.</param>
        /// <param name="style">Style data.</param>
        public virtual void SetStyle(StyleColorPicker styleColorPicker, Style style)
        {
            styleColorPicker.PaletteBorder.ApplyTo(palette.transform.parent.GetComponent <Image>());

            if (paletteCursor != null)
            {
                styleColorPicker.PaletteCursor.ApplyTo(paletteCursor.GetComponent <Image>());
            }

            if ((slider != null) && (slider.handleRect != null))
            {
                var handle_style = Utilites.IsHorizontal(slider)
                                        ? styleColorPicker.SliderVerticalHandle
                                        : styleColorPicker.SliderHorizontalHandle;
                handle_style.ApplyTo(slider.handleRect.GetComponent <Image>());
            }
        }
Esempio n. 5
0
 /// <summary>
 /// Set the specified style.
 /// </summary>
 /// <param name="styleColorPicker">Style for the ColorPicker.</param>
 /// <param name="style">Style data.</param>
 public abstract void SetStyle(StyleColorPicker styleColorPicker, Style style);