答案 0 :(得分:3)
颜色是uint值,
var color:uint;
var colorpick:ColorPicker;
color = colorpick.selectedColor;
您可能希望设置一个事件侦听器来检测何时选择新颜色。
colorpick.addEventListener(ColorPickerEvent.CHANGE, colorPicked);
function colorPicked(e:ColorPickerEvent):void {
color = (e.target as ColorPicker).selectedColor;
}