Olivier Guyot
433bccd207
Linting and fixes for unit tests
2019-02-22 15:01:30 +01:00
Olivier Guyot
e023c144bb
View / add adjust* methods to manipulate the view more easily
...
API changes:
* (breaking) the `rotate` method is gone
* the `adjustRotation`, `adjustResolution` and `adjustZoom` methods are now
available and allow using an anchor.
This means interactions do not have to do the anchor computation themselves
and this also fix anchor computation when constraints must be applied.
2019-02-22 15:01:30 +01:00
jahow
cd186ada7f
Add new tests for View & Interaction w/ fixes
2019-02-22 15:01:30 +01:00
Olivier Guyot
1f379a06a4
View / add support for viewport extent constraint
...
This introduces a breaking change:
The `extent` view option now constrains the whole viewport and not just the
view center.
The option `constrainOnlyCenter` was added to keep the previous behaviour.
Constraining the whole viewport and not only the view center means
that the center and resolution constraints must be applied with a knowledge of
the viewport size.
2019-02-22 15:01:30 +01:00
Kevin Schmidt
07349de59b
Add tests for interaction event handlers
2018-10-03 06:59:18 -06:00
Tim Schaub
40486a0ecc
Avoid shadowing EventTarget
2018-07-26 10:14:58 -06:00
Tim Schaub
1404e9d61d
Remove remaining static members from Interaction
2018-02-25 12:46:57 -07: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
1c1f008238
Rename _ol_View_ to View
2018-01-10 09:35:42 -07:00
Ron Young
9fa59d0735
rename map in tests
2017-12-21 23:11:42 -07:00
Marc Jansen
4a1d50730b
Rename _ol_interaction_Interaction_ to Interaction
2017-12-15 09:39:10 -07: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
46bcce464f
Add missing requires to tests
2017-08-16 13:43:28 -04:00
Thomas Chandelle
395d833dd6
Constrain the center in zoomByDelta
2017-01-06 09:31:00 +01:00
Tim Schaub
ed5dbd1293
Put test requires on top
2016-08-08 09:58:11 -06: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
d07185e8f2
Add an "handleEvent" interaction option
2014-12-12 18:30:31 +01:00
Éric Lemoine
dede4f379f
Make interaction "active" an ol.Object property
2014-09-29 17:31:58 +02:00
Tim Schaub
009f7b53a1
Make interactions event targets
2013-11-07 16:39:05 -07:00
Tim Schaub
7d2d68c011
Give interactions a reference to the map
...
This is in line with what we do for controls and overlays. A follow-up change will add calls to `setMap` when interactions are added to a map.
2013-10-31 09:25:52 -06:00