new vcs.vcm.widgets.BalloonInfo(options)
| Name | Type | Description |
|---|---|---|
options |
vcs.vcm.widgets.BalloonInfo.Options |
Extends
Members
-
active{boolean}
-
-
className{string}
-
class Name of the Object
-
initialized{boolean}
-
-
name{string}
-
unique Name
Methods
-
addTypeForLayer(layerName, template, minTop, minLeft)
-
Adds a balloonType for a specific layer. this function will overwrite
Name Type Default Description layerNamestring templatestring | Array.<string> set the html for the balloon, is run through the underscore template engine for the display of attributes http://underscorejs.org/#template template -
minTopstring balloonHeight+30 sets the amount of pixels the balloon is to be offsetted in the UP direction (for example: "minTop" : "balloonHeight + 30" )
minLeftstring 70 sets the amount of pixels the balloon is to be offsetted in the LEFT direction (for example: "minLeft" : "balloonWidth + 70" )
-
clearBalloon()
-
Clears the currently active balloon
-
createBalloonForGenericFeature(genericFeature)
-
Create a balloon for the genericFeature according to the configuration of this widget
Name Type Description genericFeaturevcs.vcm.widgets.BalloonInfo.GenericFeature Object literal containing the genericFeature for which to create the balloon
-
getBalloon(){vcs.vcm.util.Balloon}
-
Returns the current balloon
- Deprecated
- 3.5
-
getClassName(){string} inherited
-
returns the class name of this object.
- Deprecated
- Yes
Returns:
className
-
getConfigObject(){Object} inherited
-
-
getId(){string} inherited
-
returns the id of this object
- Deprecated
- Yes
-
getName(){string} inherited
-
returns the name of the Object, the name is either given by the config Object or a uuid is generated
- Deprecated
- Yes
-
getSupportedMaps(){Array.<string>} inherited
-
Returns the widgets supported maps
-
hasTypeForLayerName(layerName){boolean}
-
Tests whether a specific balloonType was registered for a layerName
Name Type Description layerNamestring -
isActive(){boolean} inherited
-
returns the active state of the widget
- Deprecated
- v3.6 use the property active directly
Returns:
state of the widget
-
isInitialized(){boolean} inherited
-
checks if the Widget is already initialized
- Deprecated
- Yes
Returns:
true if all requirements are there
-
isSupported(map){boolean} inherited
-
returns true if this widget supports the given map. Should be overriden by the widget
Name Type Description mapstring | vcs.vcm.maps.Map the map or className to check for support
Type Definitions
-
vcs.vcm.widgets.BalloonInfo.BalloonType{Object}
-
Properties:
Name Type Description templatestring | Array.<string> set the html for the balloon, is run through the underscore template engine for the display of attributes http://underscorejs.org/#template template -
minTopstring sets the amount of pixels the balloon is to be offsetted in the UP direction (for example: "minTop" : "balloonHeight + 30" )
minLeftstring sets the amount of pixels the balloon is to be offsetted in the LEFT direction (for example: "minLeft" : "balloonWidth + 70" )
layerNamesArray.<string> the names of the layers for which to use this template and offset (for example: ["myBuildingLayer"] ) in case of ambiguity: layerNames has precendence over layerTypes
layerTypesArray.<string> the layer types for which to use this template and offset (for example: ["vcs.vcm.layer.cesium.Buildings"] ) in case of ambiguity: layerNames has precendence over layerTypes
-
vcs.vcm.widgets.BalloonInfo.GenericFeature{Object}
-
Properties:
Name Type Description attributesObject key-value pairs of the attributes, passed to template of the
BalloonTypelatitudenumber latitude
longitudenumber longitude
heightnumber height
layerNamestring as reference to the balloonTypes
layerClassstring as reference to the balloonTypes
relativeToGroundboolean whether to use the height as relative to ground or absolute (above ellipsoid)
virtualcityMAP 3.6