Skip to main content

Search and Top Navigation

#5743 closed bug (fixed)

Opened June 19, 2010 08:45AM UTC

Closed July 08, 2010 04:11PM UTC

Last modified November 19, 2010 06:25PM UTC

$.fn.remove does not trigger remove event for <select>s

Reported by: sciyoshi Owned by:
Priority: minor Milestone: 1.8.3
Component: ui.widget Version: 1.8.2
Keywords: select, option, remove, widget, dropdown Cc:
Blocked by: Blocking:

Minimal test case:

    .bind('remove', function() {
        alert('This dialog should show...');

This code used to work with jQuery 1.3 but no longer works with 1.4, breaking certain widgets that are meant to be attached to <select> elements (in my case, jquery-dropdownchecklist).

The bug is caused by behaviour changed in jQuery 1.4: $.makeArray (called by $.fn.add) now checks for a length property, which a <select> DOM element will have.

Attachments (0)
Change History (4)

Changed June 19, 2010 08:57AM UTC by sciyoshi comment:1

Changed July 08, 2010 04:11PM UTC by scottgonzalez comment:2

milestone: TBD1.9
resolution: → fixed
status: newclosed

Fixed in 89c0961. Thanks sciyoshi.

Changed August 04, 2010 01:30AM UTC by scottgonzalez comment:3


Changed November 19, 2010 06:25PM UTC by Samuel Cormier-Iijima comment:4

Core (widget): don't pass DOM objects to $.fn.add. Fixes #5743 ($.fn.remove does not trigger remove event for <select>s)

Changeset: 89c0961c3849db0d804b337f2d438c822074b112