Opened 7 years ago

Closed 7 years ago

#9661 closed feature (wontfix)

Widget Factory _on() could make it easier to apply multiple handlers

Reported by: mattros Owned by:
Priority: minor Milestone: none
Component: ui.widget Version: 1.10.3
Keywords: Cc:
Blocked by: Blocking:

Description

Widget Factory's _on() method, because it uses a map to accept handlers, makes it clunky to apply multiple handlers to the same event-selector combination. You have to do:

this._on($element, { 'click .class' : functionOne } );
this._on($element, { 'click .class' : functionTwo } );

If the map values could be arrays of functions, that would be very convenient:

this._on($element, { 'click .class' : [ functionOne, functionTwo ] } );

Change History (1)

comment:1 Changed 7 years ago by Scott González

Resolution: wontfix
Status: newclosed

I'd rather not complicate this signature even more.

Note: See TracTickets for help on using tickets.