API Documentation | All Packages | All Classes | Index | Frames No Frames |
Class LayerSwitcher

Package | org.openscales.component.control.layer
Class | public class LayerSwitcher
Inheritance | LayerSwitcher Control mx.containers.Canvas

Public Properties
Hide Inherited Public Properties
Show Inherited Public Properties

| Property | Defined by
--- | --- | ---
|  | active : Boolean | Control
|  | baseLayerArray : Array [read-only] | LayerSwitcher
|  | fxmap : FxMap | Control
|  | map : Map [write-only] Set the map | LayerSwitcher
|  | overlayArray : Array [read-only] Switch the display base layer | LayerSwitcher
|  | position : Pixel | Control

Protected Properties
Hide Inherited Protected Properties
Show Inherited Protected Properties

| Property | Defined by
--- | --- | ---
|  | _active : Boolean = false | Control
|  | _fxmap : FxMap = null | Control
|  | _isInitialized : Boolean = false Store if this control have been initialized (Event.COMPLETE has been thrown) | Control
|  | _map : Map = null | Control

Public Methods
Hide Inherited Public Methods
Show Inherited Public Methods

| Method | Defined by
--- | --- | ---
|  | changeLayerOrder(event:DragEvent):void Update layers order when a user change it | LayerSwitcher
|  | draw():void | Control
|  | refresh(event:LayerEvent):void Refresh the LayerSwitcher when a layer is add, delete or update | LayerSwitcher

Protected Methods
Hide Inherited Protected Methods
Show Inherited Protected Methods

| Method | Defined by
--- | --- | ---
|  | onCreationComplete(event:Event):void The Flex side of the control has been created, so activate the control if needed and if the map has been set | Control
|  | onFxMapCreationComplete(event:Event):void Flex Map wrapper initialization | Control

Property detail

baseLayerArray | property

`baseLayerArray:Array` [read-only]Implementation
`public function get baseLayerArray():Array`

map | property |

`map:Map` [write-only]

Set the map

Implementation
`public function set map(value:Map):void`

overlayArray | property |

`overlayArray:Array` [read-only]

Switch the display base layer

Implementation
`public function get overlayArray():Array`
Method detail

changeLayerOrder | () | method

`public function changeLayerOrder(event:DragEvent):void`

Update layers order when a user change it

Parameters

| `event:DragEvent` — Drag event

refresh | () | method |

`public function refresh(event:LayerEvent):void`

Refresh the LayerSwitcher when a layer is add, delete or update

Parameters

| `event:LayerEvent` — Layer event