Commit Graph

39 Commits

Author SHA1 Message Date
ahocevar
a38a331085 Allow for events on other elements than the map viewport.
Not registering browser events as priority events makes it easy for controls to preventDefault or stopPropagation when events are registered on children of the map viewport element.
2012-07-08 12:14:26 +02:00
ahocevar
e67e9049ca preventDefault and stopPropagation convenience functions.
These functions can directly be used as browser event listeners.
2012-07-08 12:12:19 +02:00
ahocevar
e8ac3f1a6b preventDefault for mousemove and touchmove.
This avoids panning of the browser page when drag-panning the map.
2012-07-08 11:55:31 +02:00
ahocevar
f962b78caa If no listeners are registered, triggerEvent does nothing now. 2012-06-25 06:32:10 +02:00
ahocevar
87459deb65 Removing unused variable. 2012-06-25 06:32:10 +02:00
ahocevar
9758910fc6 Making Element/Node types more consistent. 2012-06-24 22:12:38 +02:00
ahocevar
eabc2d9922 Shortcut to register events. 2012-06-24 20:03:58 +02:00
ahocevar
1b93856e89 Keep track of the number of events we have registered.
This is needed to reliably prevent the handleBrowserEvent method to perform potentially expensive calculations.
2012-06-24 20:03:16 +02:00
ahocevar
d8599f28b9 Let the controls decide about stopPropagation and preventDefault. 2012-06-24 19:53:42 +02:00
ahocevar
68498bc36e Fixing the way we prevent the extra click. 2012-06-24 19:48:59 +02:00
ahocevar
fcadf842e5 stopPropagation and preventDefault when the event was handled. 2012-06-24 13:43:11 +02:00
ahocevar
446a434c06 New isEnterOrSpace method for keyboard navigation. 2012-06-24 13:42:34 +02:00
ahocevar
7f01528311 Proper destruction. 2012-06-24 13:41:00 +02:00
ahocevar
2fbb29efa0 Using goog.object.clear in destroy. 2012-06-24 12:46:09 +02:00
ahocevar
43adc61b26 No click event at the end of a drag sequence. 2012-06-23 14:18:02 +02:00
ahocevar
e03595fdac Priority flag for unregistering priority events. 2012-06-23 13:37:39 +02:00
ahocevar
c72f803038 Adding scroll sequence and scroll support for the Navigation control. 2012-06-22 19:51:35 +02:00
ahocevar
f504fe87b8 Removing incorrect comments. 2012-06-22 18:27:06 +02:00
ahocevar
84ee96fbd0 Don't subclass fx.Dragger - just use it. 2012-06-22 18:27:06 +02:00
ahocevar
d9537b558a Simplified ISequence API; add object property also for browser events. 2012-06-22 17:12:29 +02:00
ahocevar
65ae7eb7a7 Adding 'object' property to event object. 2012-06-22 15:58:58 +02:00
ahocevar
494305d725 Simplified the ISequence interface and sequence event handling. 2012-06-22 14:14:10 +02:00
ahocevar
deb84cf212 Removing unused code. 2012-06-22 11:42:17 +02:00
ahocevar
188615391d Using a map for controls also. 2012-06-21 19:33:33 +02:00
ahocevar
9bd507e9b8 Adding a map of sequence providers 2012-06-21 19:27:18 +02:00
ahocevar
8d8819ec3c Removing unused file and code. 2012-06-21 17:30:23 +02:00
ahocevar
81a55eb320 Finally fixing event sequences. 2012-06-21 17:26:23 +02:00
ahocevar
5b747cf7fd Temporarily removing Drag sequence. 2012-06-21 14:14:36 +02:00
ahocevar
6213e07f96 Navigation control with Drag sequence Dragger
This is totally unfinished, but tests pass, and it is only meant to give the map a Navigation control.
2012-06-21 14:08:50 +02:00
ahocevar
a36972fd35 Exporting the API. 2012-06-20 19:07:11 +02:00
ahocevar
74d1a06177 No need for cross browser handling here. 2012-06-20 19:07:11 +02:00
ahocevar
05e13e86a3 Adding drag sequence. Tests still missing. 2012-06-20 18:32:27 +02:00
ahocevar
f74d265dec Verified isSingleTouch and isMultiTouch functions. 2012-06-20 16:02:41 +02:00
ahocevar
8c4b528ded Better cleanup. 2012-06-20 15:52:24 +02:00
ahocevar
80f76a91e1 Always provide a proper event object. 2012-06-20 15:52:08 +02:00
ahocevar
2fa71057b1 Finalizing tests for ol.Events 2012-06-20 15:26:02 +02:00
ahocevar
25d4ef17fd Fixing types and getting rid of evt.touches warning. 2012-06-20 11:23:48 +02:00
ahocevar
dfc35282ff Fixing API docs 2012-06-20 09:59:19 +02:00
ahocevar
fb8b1e878d Events.js ported, with tests stub. More tests to be added. 2012-06-20 01:09:21 +02:00