com.supermap.web.events
public class DrawEvent
继承 DrawEvent Inheritance flash.events.Event

绘图操作事件类.

该类目前提供了绘图开始、绘图结束两种事件类型。



公共属性
  属性 定义方
    endPoint : Point2D
[read-only] 绘制操作的终点坐标。
DrawEvent
    feature : Feature
[read-only] 设置与当前事件关联的矢量要素 Feature。
DrawEvent
    startPoint : Point2D
[read-only] 绘制操作的起点坐标。
DrawEvent
公共方法
  方法 定义方
   
DrawEvent(type:String, feature:Feature = null, startPoint:Point2D = null, endPoint:Point2D = null)
初始化 DrawEvent 类的新实例。
DrawEvent
公共常量
  常量 定义方
    DRAW_CANCEL : String = drawCancel
[static] 定义绘制取消事件的 type 属性值,当在绘制过程中切换地图 action 时,当前绘制操作会自动取消,并派发该事件。
DrawEvent
    DRAW_END : String = drawEnd
[static] 定义绘制结束事件的 type 属性值,当双击结束时触发该事件。
DrawEvent
    DRAW_START : String = drawStart
[static] 定义绘制开始事件的 type 属性值,当鼠标第一次按下时触发该事件。
DrawEvent
    DRAW_UPDATE : String = drawUpdate
[static] 定义绘制刷新事件的 type 属性值,对于绘制自由线或自由面操作,当鼠标移动时触发发该事件;对于其它普通的绘制操作,当鼠标按下时触发该事件。
DrawEvent
属性详细信息
endPoint 属性
endPoint:Point2D  [read-only]

绘制操作的终点坐标。


Implementation
    public function get endPoint():Point2D
feature 属性  
feature:Feature  [read-only]

设置与当前事件关联的矢量要素 Feature。


Implementation
    public function get feature():Feature
startPoint 属性  
startPoint:Point2D  [read-only]

绘制操作的起点坐标。


Implementation
    public function get startPoint():Point2D
构造函数详细信息
DrawEvent () 构造函数
public function DrawEvent(type:String, feature:Feature = null, startPoint:Point2D = null, endPoint:Point2D = null)

初始化 DrawEvent 类的新实例。

参数
type:String — 事件类型。
 
feature:Feature (default = null) — 与当前事件关联的矢量要素 Feature。
 
startPoint:Point2D (default = null)
 
endPoint:Point2D (default = null)
常量描述
DRAW_CANCEL 常量
public static const DRAW_CANCEL:String = drawCancel

定义绘制取消事件的 type 属性值,当在绘制过程中切换地图 action 时,当前绘制操作会自动取消,并派发该事件。

DRAW_END 常量  
public static const DRAW_END:String = drawEnd

定义绘制结束事件的 type 属性值,当双击结束时触发该事件。

DRAW_START 常量  
public static const DRAW_START:String = drawStart

定义绘制开始事件的 type 属性值,当鼠标第一次按下时触发该事件。

DRAW_UPDATE 常量  
public static const DRAW_UPDATE:String = drawUpdate

定义绘制刷新事件的 type 属性值,对于绘制自由线或自由面操作,当鼠标移动时触发发该事件;对于其它普通的绘制操作,当鼠标按下时触发该事件。