Heron.widgets.LayerTreePanel
¶
-
class
Heron.widgets.
LayerTreePanel
(config)¶
A panel designed to hold trees of Map Layers.
Config Options¶
Configuration properties in addition to those listed for Ext.tree.TreePanel.
-
contextMenu
Context menu (right-click) for layer nodes, for now instance of Heron.widgets.LayerNodeContextMenu. Default value is null.
-
layerIcons
Which icons to use for Layers in LayerNodes. Values ‘default’ (use Ext JS standard icons), ‘ bylayertype’ (Layer-type specific icons, e.g. for raster and vector) or ‘none’ (no, i.e. blanc icon). Default value is default’. Used, unless the Layer Nodes (gx_layer entries) are explicitly configured with an ‘iconCls’, ‘cls’ or ‘icon’ config attribute.
-
lines
Flag for showing tree lines default value is “false”.
-
ordering
Ordering of layer in the map comparerd to custom layertree default value is “none” (behaviour as in older versions) valid values: ‘TopBottom’, ‘none’
-
textbaselayers
default value is “Base Layers”. Only valid if not using the ‘hropts’ option
-
textoverlays
default value is “Overlays”. Only valid if not using the ‘hropts’ option
-
title
default value is “Layers”.
-
useMapContext
Use the Heron Map Context (HMC) provided by Heron.App. The HMC defines a LayerTree. Default value is false.
Public Methods¶
Public methods in addition to those listed for Ext.tree.TreePanel.
-
LayerTreePanel.
selectLayer
()¶ Parameters: record – GeoExt.data.LayerRecord`
Layer record. Call with no layer record to remove layer selection.TODO: change to selectLayers (plural)
Events¶
Events in addition to those listed for Ext.tree.TreePanel.
-
beforelayerselectionchange
Fired before the selected set of layers changes. Listeners can return
false
to stop the selected layers from being changed.Listeners arguments:
- layerRecord -
GeoExt.data.LayerRecord
the record of the selected layer, or null if no layer is selected.
- layerRecord -
-
layerselectionchange
Fired when the selected set of layers changes.
Listeners arguments:
- layerRecord -
GeoExt.data.LayerRecord
the record of the selected layer, or null if no layer is selected.
- layerRecord -