Class: GeolocationBar

ol.control. GeolocationBar


new GeolocationBar( [options])

Control bar for OL3 The control bar is a container for other controls. It can be used to create toolbars. Control bars can be nested and combined with ol.control.Toggle to handle activate/deactivate.

Parameters:
Name Type Argument Description
options Object <optional>

Control options.

Properties
Name Type Description
className String

class of the control

centerLabel String

label for center button, default center

Extends

Methods


addControl(c)

Add a control to the bar

Parameters:
Name Type Description
c _ol_control_

control to add

Inherited From:

deactivateControls(except)

Deativate all controls in a bar

Parameters:
Name Type Description
except _ol_control_

a control

Inherited From:

getControls()

Get controls in the panel

Parameters:
Type Description
Array.<_ol_control_>
Inherited From:

getControlsByName(name)

Parameters:
Name Type Description
name string

of the control to search

Inherited From:
Returns:
Type
ol.control.Control

getInteraction()

Get the ol.interaction.GeolocationDraw associatedwith the bar


getVisible()

Get the control visibility

Inherited From:
Returns:

b

Type
boolean

onActivateControl_(e)

Post-process an activated/deactivated control

Parameters:
Name Type Description
e ol.event

:an object with a target {ol_control} and active flag {bool}

Inherited From:

setActive(b)

Auto activate/deactivate controls in the bar

Parameters:
Name Type Description
b boolean

activate/deactivate

Inherited From:

setMap(map)

Set the map instance the control is associated with and add its controls associated to this map.

Parameters:
Name Type Description
map _ol_Map_

The map instance.

Inherited From:

setPosition(pos)

Set tool bar position

Parameters:
Name Type Description
pos top | left | bottom | right
Inherited From:

setVisible(b)

Set the control visibility

Parameters:
Name Type Description
b boolean
Inherited From: