滑动选择器
//2.11滑动选择器
//水平滑块
private initHslider():void{
var hslider: eui.HSlider = new eui.HSlider();
hslider.width = 200;
hslider.x = 100;
hslider.y = 100;
hslider.maximum = 100;
hslider.minimum = 0;
hslider.value = 0;
hslider.addEventListener(eui.UIEvent.CHANGE,(evt:eui.UIEvent)=>{egret.log(evt.target.value)},this);
this.addChild(hslider);
}
//垂直滑块
private initVslider():void{
var vslider: eui.VSlider = new eui.VSlider();
vslider.height = 100;
vslider.x = 200;
vslider.y = 200;
vslider.maximum = 100;
vslider.minimum = 0;
vslider.value = 0;
vslider.addEventListener(eui.UIEvent.CHANGE,(evt:eui.UIEvent)=>{egret.log(evt.target.value)},this);
this.addChild(vslider);
}