Beispiel #1
0
        public EleSlider CreateHorizontalSlider(EleBaseRect parent, Vector2 size, string name = "")
        {
            EleSlider ele = new EleSlider(parent, this.horizSlider, size, name);

            ele.Slider.direction = UnityEngine.UI.Slider.Direction.LeftToRight;
            onCreateSlider?.Invoke(ele.Slider);

            return(ele);
        }
Beispiel #2
0
        public EleSlider CreateHorizontalSlider()
        {
            if (this.head.rect == null)
            {
                return(null);
            }

            EleSlider sldr = this.uiFactory.CreateHorizontalSlider(this.head.rect);

            return(sldr);
        }
Beispiel #3
0
        public EleSlider AddHorizontalSlider(float proportion, LFlag flags)
        {
            EleBaseSizer szr = this.head.GetSizer();

            if (szr == null)
            {
                return(null);
            }

            EleSlider sldr = this.uiFactory.CreateHorizontalSlider(this.head.rect);

            szr.Add(sldr, proportion, flags);
            return(sldr);
        }