Documentation
Reference
2.1.50 (current version)
collection
interactivityModel
Interfaces
2.1.52 (release candidate)
collection
interactivityModel
Interfaces

overlay.html.Balloon

Extends IOverlay.

HTML overlay for the balloon. By default, the overlays have not been added to package.full (the standard set of modules). To create your own overlay instance, use overlay.storage.

Constructor | Fields | Events | Methods

Constructor

overlay.html.Balloon(geometry[, data[, options]])

Parameters:

ParameterDefault valueDescription
geometry *
[no-highlight[

* Mandatory parameter/option.

]no-highlight]

Type: IPixelPointGeometry

Pixel geometry of a shape.

data

Type: Object

Data.

options

Type: Object

Options.

options.cursor

Type: String

Cursor when the mouse is hovering.

options.interactivityModel "default#opaque"

Type: String

Interactivity model. Available keys and their values are listed in the description of interactivityModel.storage.

options.layout

Type: Function|String

Layout. (Type: constructor for an object with the ILayout interface).

options.offset [0,0]

Type: Array

Offset in pixels.

options.pane "balloon"

Type: String

Container where the balloon layout will be placed.

options.shadow true

Type: Boolean

Flag for whether there is a shadow.

options.shadowLayout

Type: Function|String

Shadow layout (type: constructor for an object with the ILayout interface).

options.shadowOffset [0,0]

Type: Array

Shadow offset in pixels.

options.shadowsPane "shadows"

Type: Array

Container where the balloon shadow layout will be placed.

options.zIndex

Type: Number

The z-index of the element.

* Mandatory parameter/option.

Fields

NameTypeDescription
eventsIEventManager

Event manager.

Inherited from IDomEventEmitter.

optionsIOptionManager

Options manager.

Inherited from ICustomizable.

Events

NameDescription
click

Single left-click on the object. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

contextmenu

Calls the element's context menu. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

datachange

Data change. Data fields:

  • oldData - Old data.
  • newData - New data.

Inherited from IOverlay.

dblclick

Double left-click on the object. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

emptinesschange

Change to the empty overlay flag. Instance of the Event class.

Inherited from IOverlay.

geometrychange

Changed geometry. Data fields:

  • oldGeometry - Old pixel geometry.
  • newGeometry - New pixel geometry.

Inherited from IOverlay.

mapchange

Map reference changed. Data fields:

  • oldMap - Old map.
  • newMap - New map.

Inherited from IOverlay.

mousedown

Pressing the mouse button over the object. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

mouseenter

Pointing the cursor at the object. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

mouseleave

Moving the cursor off of the object. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

mousemove

Moving the cursor over the object. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

mouseup

Letting go of the mouse button over an object. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

multitouchend

End of multitouch. This event is only available on devices that support multitouch. Returns an implementation of the IMultiTouchEvent interface.

Inherited from IDomEventEmitter.

multitouchmove

Repeating event during multitouch. This event is only available on devices that support multitouch. Returns an implementation of the IMultiTouchEvent interface with information about touches. Defines the touches property, which contains a list of touches. Every touch is described by an object that contains the following fields:

  • clientX - X coordinate of the touch relative to the viewable area of the browser.
  • clientY - Y coordinate of the touch relative to the viewable area of the browser.
  • pageX - X coordinate of the touch relative to the beginning of the document.
  • pageY - Y coordinate of the touch relative to the beginning of the document.

Inherited from IDomEventEmitter.

multitouchstart

Start of multitouch. This event is only available on devices that support multitouch. Returns an implementation of the IMultiTouchEvent interface with information about touches. Defines the touches property, which contains a list of touches. Every touch is described by an object that contains the following fields:

  • clientX - X coordinate of the touch relative to the viewable area of the browser.
  • clientY - Y coordinate of the touch relative to the viewable area of the browser.
  • pageX - X coordinate of the touch relative to the beginning of the document.
  • pageY - Y coordinate of the touch relative to the beginning of the document.

Inherited from IDomEventEmitter.

optionschange

Change to the object options.

Inherited from ICustomizable.

shapechange

Change to the shape of the area spanning the overlay. Instance of the Event class.

Inherited from IOverlay.

wheel

Mouse wheel scrolling. When using, keep in mind that mouse events are emulated when a touch screen is used. More information is available in domEvent.manager.

Inherited from IDomEventEmitter.

Methods

NameReturnsDescription
getBalloonElement()

HTMLElement

Returns parent element of the balloon layout.

getBalloonLayout()

vow.Promise

Returns Promise object to return the balloon layout.

getBalloonLayoutSync()

ILayout

Returns balloon layout.

getData()

Object

Returns the overlay data object.

Inherited from IOverlay.

getElement()

HTMLElement

Returns parent element of the balloon layout.

getGeometry()

IPixelGeometry

Returns the current pixel geometry.

Inherited from IOverlay.

getLayout()

vow.Promise

Returns Promise object to return the balloon layout.

getLayoutSync()

ILayout|null

Returns balloon layout.

getMap()

Map|null

Returns reference to the current map.

Inherited from IOverlay.

getMode()

String

Returns the current mode of the balloon: "panel" — panel mode, "standard" — standard display.

getShadowElement()

HTMLElement

Returns parent element of the balloon shadow layout.

getShadowLayout()

vow.Promise

Returns Promise object to return the balloon shadow layout.

getShadowLayoutSync()

ILayout|null

Returns balloon shadow layout.

getShape()

IShape|null

Returns a shape that defines the area spanning the overlay in global pixel coordinates, or null if it is not possible to plot the shape.

Inherited from IOverlay.

isEmpty()

Boolean

Returns true if the layout is empty or if the layout has not yet been loaded, i.e. it has no content.

setData(data)

Sets the overlay data.

Inherited from IOverlay.

setGeometry(geometry)

Sets the overlay pixel geometry.

Inherited from IOverlay.

setMap(map)

Sets the map on which to display the overlay.

Inherited from IOverlay.

Methods details

getBalloonElement

{HTMLElement} getBalloonElement()

Returns parent element of the balloon layout.

getBalloonLayout

{vow.Promise} getBalloonLayout()

Returns Promise object to return the balloon layout.

getBalloonLayoutSync

{ILayout} getBalloonLayoutSync()

Returns balloon layout.

getElement

{HTMLElement} getElement()

Returns parent element of the balloon layout.

getLayout

{vow.Promise} getLayout()

Returns Promise object to return the balloon layout.

getLayoutSync

{ILayout|null} getLayoutSync()

Returns balloon layout.

getMode

{String} getMode()

Returns the current mode of the balloon: "panel" — panel mode, "standard" — standard display.

getShadowElement

{HTMLElement} getShadowElement()

Returns parent element of the balloon shadow layout.

getShadowLayout

{vow.Promise} getShadowLayout()

Returns Promise object to return the balloon shadow layout.

getShadowLayoutSync

{ILayout|null} getShadowLayoutSync()

Returns balloon shadow layout.

isEmpty

{Boolean} isEmpty()

Returns true if the layout is empty or if the layout has not yet been loaded, i.e. it has no content.