From 2e2fdad63488930262d09724a3e04d5350b720f1 Mon Sep 17 00:00:00 2001 From: David Rogers Date: Tue, 25 Mar 2014 11:41:14 -0700 Subject: [PATCH] Add support for optional event data. --- jquery/jquery.d.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jquery/jquery.d.ts b/jquery/jquery.d.ts index b42f77aaa..2d98b338b 100644 --- a/jquery/jquery.d.ts +++ b/jquery/jquery.d.ts @@ -2671,7 +2671,7 @@ interface JQuery { * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. */ - on(events: string, selector: string, handler: (eventObject: JQueryEventObject) => any): JQuery; + on(events: string, selector: string, handler: (eventObject: JQueryEventObject, ...eventData: any[]) => any): JQuery; /** * Attach an event handler function for one or more events to the selected elements. * @@ -2680,7 +2680,7 @@ interface JQuery { * @param data Data to be passed to the handler in event.data when an event is triggered. * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. */ - on(events: string, selector: string, data: any, handler: (eventObject: JQueryEventObject) => any): JQuery; + on(events: string, selector: string, data: any, handler: (eventObject: JQueryEventObject, ...eventData: any[]) => any): JQuery; /** * Attach an event handler function for one or more events to the selected elements. *