Commit Graph

15 Commits

Author SHA1 Message Date
Daan Mortier
c6620859e4 Updated patch for issue #1631 based on feedback 2013-04-29 13:03:05 +02:00
Daan Mortier
52498f1ef9 Issue #1631: Fixed a bug on removeEventListener
Bugfix for issue #1631 where removeEventListener would throw when no event listeners are registered on the object.
2013-04-29 11:53:16 +02:00
Vladimir Agafonkin
5647f37ae6 cleanup and merge #1596, adds Events#once 2013-04-19 17:23:45 +03:00
iirvine
84ad7db070 clearEventListeners -> clearAllListeners 2013-04-15 14:09:32 -07:00
iirvine
2d5bf783fe initial commit of #clearEventListeners 2013-04-15 14:09:32 -07:00
John Firebaugh
81f21125d4 Update specs for mocha 2013-04-03 15:22:45 -07:00
Tom MacWright
a2f7d7e834 Use mocha 2013-04-03 14:50:09 -07:00
danzel
9d4d894450 Add another events test and fix from @iirvine 2013-03-15 13:53:03 +13:00
danzel
44cbed0b5e Replace the FeatureGroup test with a better one in events, this one currently fails 2013-03-13 10:08:04 +13:00
John Firebaugh
01332ebead Omit "should" in spec descriptions
The rationale is this: the spec string describes the expected
behavior unconditionally. The code examples, on the other hand,
set up an expectation that is tested with the call to the expect
method. The code examples can violate the expectation, but the
spec string does not. The value of the spec string is as clearly
as possible describing the behavior. Including “should” in that
description adds no value. (From http://rubyspec.org/style_guide/)
2013-02-19 12:41:48 -08:00
Tom MacWright
0a2000166a Fix semicolons, breaking, whitespace, duplicate var statements. 2013-02-19 11:18:15 -05:00
Vladimir Agafonkin
ed8dc9f4cd improve core specs #1347 2013-02-04 18:31:14 +02:00
Aaron King
95ed9cdda2 Allow L.Mixin.Events.addEventListener() to accept a map in which the string keys represent one or more space-separated event types and the values represent a handler function to be called for the event(s).
Allow L.Mixin.Events.removeEventListener() to accept one or more space-separated event types. Omitting the fn parameter will remove all event handlers for the supplied event type(s).

Also allow L.Mixin.Events.removeEventListener() to accept a map where the string keys represent one or more space-separated event types and the values represent handler functions previously attached for the event(s).

Add unit tests for the above changes.
2012-06-29 16:14:41 -07:00
mourner
7cef8d3851 Events fire shortcut 2010-09-10 16:54:20 +03:00
mourner
db5809b473 Events fixes, Events spec 2010-09-03 19:16:29 +03:00