internal function updateAdorner(renderer:UIComponent):void
{
var adorner:Adorner=this.getAdorner(renderer);
if (this.isSelected(renderer as BaseRenderer))
{
if (adorner == null)
{
adorner = this.createAdorner(renderer);
this.adorners[renderer] = adorner;
this.adornersGroup.addElement(adorner);
}
}
else if (adorner != null)
{
this.adornersGroup.removeElement(adorner);
this.adorners[renderer] = null;
}
return;
}
internal function createAdorner(renderer:UIComponent):Adorner
{
if (renderer is BaseRenderer)
{
return new BaseRendererAdorner(renderer);
}
throw new ArgumentError("参数有误");
}
public function getAdorner(renderer:UIComponent):Adorner
{
return Adorner(this.adorners[renderer]);
}
{
var adorner:Adorner=this.getAdorner(renderer);
if (this.isSelected(renderer as BaseRenderer))
{
if (adorner == null)
{
adorner = this.createAdorner(renderer);
this.adorners[renderer] = adorner;
this.adornersGroup.addElement(adorner);
}
}
else if (adorner != null)
{
this.adornersGroup.removeElement(adorner);
this.adorners[renderer] = null;
}
return;
}
internal function createAdorner(renderer:UIComponent):Adorner
{
if (renderer is BaseRenderer)
{
return new BaseRendererAdorner(renderer);
}
throw new ArgumentError("参数有误");
}
public function getAdorner(renderer:UIComponent):Adorner
{
return Adorner(this.adorners[renderer]);
}