| Package | flare.vis.controls |
| Class | public class SelectionControl |
| Inheritance | SelectionControl Control flash.events.EventDispatcher |
| Property | Defined by | ||
|---|---|---|---|
| fillAlpha : Number = 0.2 Fill alpha of the selection region.
| SelectionControl | ||
| fillColor : uint = 0x8888FF Fill color of the selection region.
| SelectionControl | ||
![]() | filter : Function Boolean function indicating the items considered by the control.
| Control | |
| fireImmediately : Boolean = true Indicates if a selection events should be fired immediately upon a
chane of selection status (true) or after the mouse is released
(false).
| SelectionControl | ||
| hitArea : InteractiveObject The active hit area over which selection
interactions can be performed.
| SelectionControl | ||
| lineAlpha : Number = 0.4 Line alpha of the selection region border.
| SelectionControl | ||
| lineColor : uint = 0x8888FF Line color of the selection region border.
| SelectionControl | ||
| lineWidth : Number = 2 Line width of the selection region border.
| SelectionControl | ||
![]() | object : InteractiveObject The interactive object this control is attached to.
| Control | |
| Method | Defined by | ||
|---|---|---|---|
|
SelectionControl(filter:* = null, select:Function = null, deselect:Function = null, hitArea:InteractiveObject = null)
Creates a new SelectionControl.
| SelectionControl | ||
|
attach(obj:InteractiveObject):void
Attach this control to the given interactive object.
| SelectionControl | ||
|
detach():InteractiveObject
Detach this control.
| SelectionControl | ||
|
isSelected(d:DisplayObject):Boolean
Indicates is a display object has been selected.
| SelectionControl | ||
| fillAlpha | property |
public var fillAlpha:Number = 0.2Fill alpha of the selection region.
| fillColor | property |
public var fillColor:uint = 0x8888FFFill color of the selection region.
| fireImmediately | property |
public var fireImmediately:Boolean = trueIndicates if a selection events should be fired immediately upon a chane of selection status (true) or after the mouse is released (false). The default is true. Set this to false if immediate selections are causing any performance issues.
| hitArea | property |
hitArea:InteractiveObject [read-write]The active hit area over which selection interactions can be performed.
Implementation public function get hitArea():InteractiveObject
public function set hitArea(value:InteractiveObject):void
| lineAlpha | property |
public var lineAlpha:Number = 0.4Line alpha of the selection region border.
| lineColor | property |
public var lineColor:uint = 0x8888FFLine color of the selection region border.
| lineWidth | property |
public var lineWidth:Number = 2Line width of the selection region border.
| SelectionControl | () | constructor |
public function SelectionControl(filter:* = null, select:Function = null, deselect:Function = null, hitArea:InteractiveObject = null)Creates a new SelectionControl.
Parametersfilter:* (default = null) — an optional Boolean-valued filter determining which
items are eligible for selection.
|
|
select:Function (default = null) — a display object to use as the hit area for mouse
events. For example, this could be a background region over which
the selection can done. If this argument is null,
the stage will be used.
|
|
deselect:Function (default = null) — an optional SelectionEvent listener for selections
|
|
hitArea:InteractiveObject (default = null) — an optional SelectionEvent listener for deselections
|
| attach | () | method |
public override function attach(obj:InteractiveObject):voidAttach this control to the given interactive object. This method will automatically detach if already attached to another object.
Parametersobj:InteractiveObject — the display object to attach to
|
| detach | () | method |
public override function detach():InteractiveObjectDetach this control.
ReturnsInteractiveObject — the interactive object this control was attached to,
or null if this control was not attached.
|
| isSelected | () | method |
public function isSelected(d:DisplayObject):BooleanIndicates is a display object has been selected.
Parametersd:DisplayObject — the display object
|
Boolean — true if selected, false if not
|
| deselect | event |
| select | event |