Add method for retrieving ol.Overlay by id

This commit is contained in:
jonataswalker
2015-10-14 16:01:48 -03:00
parent d29e5eaef1
commit fce065e185
5 changed files with 30 additions and 117 deletions

View File

@@ -309,7 +309,8 @@ olx.MapOptions.prototype.view;
/**
* Object literal with config options for the overlay.
* @typedef {{element: (Element|undefined),
* @typedef {{id: (number|string|undefined),
* element: (Element|undefined),
* offset: (Array.<number>|undefined),
* position: (ol.Coordinate|undefined),
* positioning: (ol.OverlayPositioning|string|undefined),
@@ -323,6 +324,15 @@ olx.MapOptions.prototype.view;
olx.OverlayOptions;
/**
* Set the overlay id. The overlay id can be used with the
* {@link ol.Map#getOverlayById} method.
* @type {number|string|undefined}
* @api
*/
olx.OverlayOptions.prototype.id;
/**
* The overlay element.
* @type {Element|undefined}