OpenLayers. | |
Properties | |
events | {<OpenLayers.Events>} Events instance for listeners and triggering specific events. |
Constants | |
EVENT_TYPES | Only required to use OpenLayers.Control.FeaturePopups with 2.11 or less |
Properties | |
eventListeners | {Object} If set on options at construction, the eventListeners object will be registered with <OpenLayers.Events.on>. |
type | {String} Type of popup manager, read only. |
popupClass | {String|<OpenLayers.Popup>|Function} Type of popup to manage. |
anchor | {Object} Object to which we’ll anchor the popup. |
minSize | {<OpenLayers.Size>} Minimum size allowed for the popup’s contents. |
maxSize | {<OpenLayers.Size>} Maximum size allowed for the popup’s contents. |
unselectFunction | {Function} Closing a popup all features are unselected using this function (used only if is not null) |
closeBox | {Boolean} To display a close box inside the popup. |
panMapIfOutOfView | {Boolean} When drawn, pan map such that the entire popup is visible in the current viewport (if necessary). |
Constructor | |
OpenLayers. | This class is a handler that is responsible for displaying and clear the one kind of popups managed by a OpenLayers.Control.FeaturePopups. |
Functions | |
destroy | |
clear | Clear the popup and related popups. |
{<OpenLayers.Events>} Events instance for listeners and triggering specific events.
beforepopupdisplayed | Triggered before a popup is displayed. To stop the popup from being displayed, a listener should return false. Receives an event with: “selection” a selection object (except for the “list” popup is an array of selection objects), “html” the html of the popup content (alter the html is allowed) Selection objects have three keys, “layerObj” (the FeaturePopups.Layer manager of the layer), “layer” (the layer) and “features” or “feature” (the singular key “feature” is used only for popupType: “single”, “hover” or “listItem”) |
popupdisplayed | Triggered after a popup is displayed. Receives an event with; “selection” (with the same structure described in the event “beforepopupdisplayed”), “div” the DOMElement used by the popup. |
closedbybox | Triggered after close a popup using close box. Receives an event with “popupType” see Constructor |
Only required to use OpenLayers.Control.FeaturePopups with 2.11 or less
This class is a handler that is responsible for displaying and clear the one kind of popups managed by a OpenLayers.Control.FeaturePopups.
The manager popup can handle three types of popups: a div a OpenLayers.Popup class or a custom popup, it depends on the type of “popupClass” argument.
environments | {OpenLayers.Control.FeaturePopups}|Array() The control that initialized this popup manager, if array first item must be the control. |
popupType | {String} Type of popup manager: “list”, “single”, “listItem” “hover” or “hoverList” |
options | {Object} |
eventListeners | {Object} Listeners to register at object creation. |
minSize | {<OpenLayers.Size>} Minimum size allowed for the popup’s contents. |
maxSize | {<OpenLayers.Size>} Maximum size allowed for the popup’s contents. |
popupClass | {String|<OpenLayers.Popup>|Function} Type of popup to manage: string for a “id” of a DOMElement, OpenLayers.Popup and a function for a custom popup. anchor -{Object} Object to which we’ll anchor the popup. Must expose a ‘size’ (<OpenLayers.Size>) and ‘offset’ (<OpenLayers.Pixel>). |
followCursor | {Boolean} If true, the popup will follow the cursor (useful for hover) |
unselectFunction | {Function} Closing a popup all features are unselected using this function (used only if is not null) |
closeBox | {Boolean} To display a close box inside the popup. |
observeItems | {Boolean} If true, will be activated observers of the DOMElement of the popup to trigger some events (mostly by list popups). |
relatedToClear | Array({String})|Array(Array({String})) Related <FeaturePopups.popupObjs> codes from <environments> to clear. |
relatedSimultaneous | {Object} Object with two keys: “axis” key is the axis on which to display the two popups (valid values are “h” or “v”) and “related” key is a code of <FeaturePopups.popupObjs> from <control> to show simultaneously without much overlap. panMapIfOutOfView -{Boolean} When drawn, pan map such that the entire popup is visible in the current viewport (if necessary), default is true. |
destroy: function()
Clear the popup and related popups.
clear: function()