Éric Lemoine
95030cd838
Add ol.interaction.Draw#extend
...
This commit adds an `extend` method to the draw interaction. This method makes it possible to extend (continue drawing) an existing line string feature. It only works on line string features, where this functionality makes the most sense.
Here's an example on how to use `extend`:
```js
var vectorSource = vectorLayer.getSource();
vectroSource.removeFeature(feature);
drawInteraction.extend(feature);
```
2015-09-02 17:21:10 +02:00
Frédéric Junod
4045e06aa9
Merge pull request #4050 from fredj/view_getState
...
Use view.getRotation and view.getResolution instead of view.getState
2015-08-26 14:15:31 +02:00
Frederic Junod
c1575e810b
Use view.getRotation and view.getResolution instead of view.getState
...
view.getState calls 4 functions and creates an object and an array.
It's more efficient to use view.getRotation and view.getResolution.
2015-08-26 13:37:30 +02:00
Frederic Junod
9d07300e71
Rename ol.SelectEvent to ol.interaction.SelectEvent
2015-08-25 09:26:10 +02:00
Frederic Junod
ffc24e892e
Rename ol.ModifyEvent to ol.interaction.ModifyEvent
2015-08-25 09:26:10 +02:00
Frederic Junod
49b8f90e66
Add missing goog.provide
...
The new version of the closure-compiler (version 20150729) wants that all the classes
tagged with `@constructor` to be provided (with `goog.provide`).
2015-08-25 09:26:10 +02:00
Frederic Junod
eb4dab90e5
Better type for ol.interaction.Modify#rBush_
2015-08-25 09:26:10 +02:00
Éric Lemoine
5f7e6ac61a
Make Modify interaction listen to feature changes
...
This commit makes the Modify interaction modify its segment data when the candidate features change.
2015-08-18 16:39:49 +02:00
Christopher S. Case
338d0570fd
Add a Translate interaction
...
This allows features to be moved around the map. It works much like the Modify interaction, however it's significantly simpler. It uses the geometry's underlying `translate` function.
2015-08-18 11:17:01 +02:00
Andreas Hocevar
0ec70256d6
Merge pull request #3875 from geonux/draw_undo
...
Undo last points method to the draw interraction
2015-08-04 20:25:02 +02:00
geonux
999880f350
Add missing braces on statement
2015-08-04 15:02:49 +02:00
Frederic Junod
0a6745f1e4
Remove unused goog.require
...
Found by the latest version of closure-compiler (v20150729)
2015-08-04 10:01:11 +02:00
Tim Schaub
85ddded15c
Only remove the vertex feature if it exists
...
When deleting a vertex shared by multiple features, we iterate through drag segments and only need to remove the vertex feature once.
2015-08-03 22:44:22 -06:00
Tim Schaub
405a8db075
Merge pull request #3946 from Turbo87/modify
...
Fix vertex deletion for Modify interaction on mobile devices.
2015-08-03 21:47:41 -06:00
Frederic Junod
2143eebd30
Fix drawstart and drawend events when drawing a point
...
The previous behavior was to fire a `drawstart` on the first `mousemove`.
2015-08-03 13:40:56 +02:00
Tobias Bieniek
c3f51c676a
interaction/modify: Fix identation issue
2015-08-01 22:05:44 +02:00
Tobias Bieniek
968c8aa34e
interaction/modify: Replace lastNewVertexPixel with ignoreNextSingleClick
...
The previous approach did not work on mobile devices where no `pointermove`
event is sent except from dragging.
Logic now is: Upon vertex creation due to `pointerdown` we will ignore
the next `singleclick` event unless there is a `pointerdrag` event, which will
not lead to a `singleclick` event following the vertex creation.
Resolves #3935
2015-08-01 22:00:41 +02:00
Tobias Bieniek
b001a48567
interaction/modify: Simplify lastNewVertexPixel condition
2015-08-01 21:12:59 +02:00
Tim Schaub
cd6ac857b9
Merge pull request #3824 from probins/select
...
Improve docs for interaction.Select.
2015-07-09 16:54:05 -06:00
geonux
64ab764827
Renaming the method description according to 'probins' proposal.
2015-07-06 15:07:56 +02:00
geonux
314b04df7a
Add assertions to pass the validation step.
2015-07-06 13:49:42 +02:00
geonux
29b1f0d55d
Add the capability to remove(undo) the last drawed segments.
2015-07-06 12:11:34 +02:00
Peter Robins
c53aa7e8d5
Correct minor typo in modifyinteraction
2015-07-05 10:57:59 +01:00
Björn Harrtell
c69ba6a3dd
Create vertex on boundary single click
2015-07-03 10:26:38 +02:00
Björn Harrtell
f81e36d8e0
Add mapBrowserPointerEvent property to ModifyEvent
2015-07-03 10:11:24 +02:00
Björn Harrtell
f7d62f054c
High level Modify interaction events
2015-07-03 10:11:24 +02:00
Frederic Junod
dd132c9fad
Add non-nullable notation to features array
2015-06-25 09:11:38 +02:00
Peter Robins
d6118f31e4
Improve docs for interaction.Select
2015-06-19 13:11:27 +00:00
Andreas Hocevar
f645a9e1e4
Make unmanaged vector layers behave more like ol.FeatureOverlay
...
* Skipped features need to be hit-detected on unmanaged layers.
* updateWhileAnimating and updateWhileInteracting are recommended to
achieve the same instant visual feedback that ol.FeatureOverlay had.
2015-06-19 13:06:29 +02:00
Éric Lemoine
b8cb1fe795
Merge pull request #3766 from elemoine/draw-click-tolerance
...
Add a clickTolerance option to the Draw interaction
2015-06-16 10:06:01 +02:00
Éric Lemoine
e99f43af8d
Add a clickTolerance option to the Draw interaction
2015-06-15 15:32:34 +02:00
Andreas Hocevar
fad3cf9672
Merge pull request #3758 from ahocevar/remove-featureoverlay
...
Removal of ol.FeatureOverlay
2015-06-10 14:33:28 +02:00
Andreas Hocevar
57e1dda5f1
Make sure that #clear() keeps the collection in sync
2015-06-09 15:44:39 +02:00
Andreas Hocevar
53d5d8c1d9
Get rid of ol.FeatureOverlay
...
This also introduces a wrapX option to the Draw, Modify and Select
interaction.
2015-06-09 15:44:31 +02:00
Peter Robins
282fdafad7
Standardise draw/modify descriptions
2015-06-05 07:54:22 +00:00
Björn Harrtell
9a9b838235
Add mapBrowserEvent as a member of ol.SelectEvent
2015-06-04 16:53:53 +02:00
Peter Robins
7f1053d2cd
Add @fires to select interaction
2015-05-29 10:59:07 +00:00
Éric Lemoine
531b35d7c2
Be consistent with the way we name types
2015-05-21 17:32:32 +02:00
Éric Lemoine
879307da1b
Add missing goog.provides in drawinteraction.js
2015-05-21 15:41:51 +02:00
Andreas Hocevar
100020fd59
Refactoring for more consistency
...
* Min and max number of points configurable for lines and polygons
* Polygons from custom geometryFunction now have a sketch line
* The example shows how to use a custom geometryFunction
2015-05-20 10:28:16 +02:00
Andreas Hocevar
19c91235ce
Add convenience function to create a regular polygon geometryFunction
2015-05-14 23:24:29 +02:00
Andreas Hocevar
250221cded
Add new geometryFunction option
...
This allows applications to control the geometry that is created from the
drawing sketch. Will e.g. be useful to create a regular polygon instead of
a circle when in Circle mode.
2015-05-14 23:24:29 +02:00
Andreas Hocevar
1d6530ce9c
Merge pull request #3616 from ahocevar/freehand-drawing
...
Add support for freehand drawing to the Draw interaction
2015-04-27 11:27:10 +02:00
tsauerwein
77f16c7fd6
Fix XYZ coordinates in snap interaction
2015-04-24 09:26:31 +02:00
Andreas Hocevar
ed424eded8
Add support for freehand drawing to the Draw interaction
2015-04-22 17:45:55 +02:00
Marc Jansen
4ea8cb7a19
Add basic docs for snapinteraction
2015-04-22 14:22:34 +02:00
Marc Jansen
a784157344
Add basic docs for selectinteraction
2015-04-22 14:22:34 +02:00
Marc Jansen
340d4805af
Add basic docs for pointerinteraction
2015-04-22 14:22:34 +02:00
Marc Jansen
5a6c95b13c
Add basic docs for mousewheelzoominteraction
2015-04-22 14:22:33 +02:00
Marc Jansen
73b103a19c
Add basic docs for modifyinteraction
2015-04-22 14:20:06 +02:00