Exemplo n.º 1
0
        /// <summary>
        /// Set the specified style.
        /// </summary>
        /// <returns><c>true</c>, if style was set for children gameobjects, <c>false</c> otherwise.</returns>
        /// <param name="style">Style data.</param>
        public virtual bool SetStyle(Style style)
        {
            var component = Compatibility.GetComponent <IStylable <StyleTabs> >(gameObject);

            if (component != null)
            {
                component.SetStyle(style.TabsTop, style);
            }

            return(true);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Set the specified style.
        /// </summary>
        /// <returns><c>true</c>, if style was set for children gameobjects, <c>false</c> otherwise.</returns>
        /// <param name="style">Style data.</param>
        public virtual bool SetStyle(Style style)
        {
            style.Combobox.Background.ApplyTo(GetComponent <Image>());

            if ((Combobox != null) && (Combobox.GetInstanceID() != gameObject.GetInstanceID()))
            {
                var stylable = Compatibility.GetComponent <IStylable>(Combobox);

                if (stylable != null)
                {
                    stylable.SetStyle(style);
                }
            }

            return(true);
        }