Commit Graph

16 Commits

Author SHA1 Message Date
Andreas Hocevar
852fe2a3fe Allow using un() for events registered with once() 2020-06-11 12:14:32 +02:00
Tim Schaub
054af09032 Make code prettier
This updates ESLint and our shared eslint-config-openlayers to use Prettier.  Most formatting changes were automatically applied with this:

    npm run lint -- --fix

A few manual changes were required:

 * In `examples/offscreen-canvas.js`, the `//eslint-disable-line` comment needed to be moved to the appropriate line to disable the error about the `'worker-loader!./offscreen-canvas.worker.js'` import.
 * In `examples/webpack/exapmle-builder.js`, spaces could not be added after a couple `function`s for some reason.  While editing this, I reworked `ExampleBuilder` to be a class.
 * In `src/ol/format/WMSGetFeatureInfo.js`, the `// @ts-ignore` comment needed to be moved down one line so it applied to the `parsersNS` argument.
2020-04-06 12:54:09 -06:00
Tim Schaub
40486a0ecc Avoid shadowing EventTarget 2018-07-26 10:14:58 -06:00
Frederic Junod
2fd75566fb Named exports from ol/Observable 2018-02-21 09:01:08 +01:00
Tim Schaub
ad62739a6e Use blocked scoped variables
In addition to using const and let, this also upgrades our linter config and removes lint (mostly whitespace).
2018-01-12 00:50:30 -07:00
Tim Schaub
35db8721b2 Rename _ol_Observable_ to Observable 2018-01-10 09:35:43 -07:00
simonseyock
d7c48314b8 observable 2017-12-19 13:15:11 +01:00
Marc Jansen
c620688758 Rename _ol_events_EventTarget_ to EventTarget 2017-12-15 16:19:03 +01:00
Tim Schaub
7f47883c48 Transformed 2017-12-12 06:53:18 -07:00
Tim Schaub
a3e3e99baa Get rid of useless test exports 2017-08-17 15:16:58 -04:00
Tim Schaub
ed5dbd1293 Put test requires on top 2016-08-08 09:58:11 -06:00
Andreas Hocevar
b2c6bb11cf Allow once listeners to dispatch events of same type 2016-05-04 11:55:30 -04:00
Andreas Hocevar
c51d717657 Refactor event manager to remove memory leaks 2016-02-03 11:19:38 +01:00
Andreas Hocevar
3f2d79b7fe Replace goog.events.Event/EventTarget system with our own
This also removes goog.events.listen, goog.events.unlisten,
goog.events.unlistenByKey and goog.events.BrowserEvent.
2016-02-03 11:19:38 +01:00
Éric Lemoine
b832c42585 Add ol.Observable.unByKey 2014-10-08 14:41:45 +02:00
Tim Schaub
3dc40f8cb6 Add ol.Observable for on, once, un, and unByKey methods 2013-12-05 12:27:30 -07:00