Bug Tracker

Modify

Ticket #2292 (closed bug: duplicate)

Opened 5 years ago

Last modified 15 months ago

tablesorter or jQuery? duplicate event handler, possible memory leaks

Reported by: Max_B Owned by: christian
Priority: major Milestone: 1.2.3
Component: plugin Version: 1.2.2
Keywords: tablesorter event clone Cc:
Blocking: Blocked by:

Description

If there is an event handler attached to a row element or any of its children, it is loosen when sorting occurs. Rows are cloned in the process (empty/append). Then i tried using tablesorter widget to add handle. That the weird side: the event handler is now called several times (as many as there has been sort on the table). I even tried to hack the plugin to add an unbind widget before sorting. I worked for unbinding on row children events, but not on the row itself. Those rows have id attribute and that might raise some conflict.

I'm not sure if the same handler is called several times on the same element or if there ares several clones responding to the event and thus memory leaks.

Currently i had to workaround by watching event.timeStamp in the handler and discard duplicate.

Change History

comment:1 in reply to: ↑ description Changed 5 years ago by Max_B

While posting this bug, I saw 1.2.2! I missed it. This is corrected in 1.2.2. Please close this one as duplicate/fixed.

comment:2 Changed 5 years ago by paul

  • Owner changed from paul to christian

comment:3 Changed 5 years ago by paul

  • Component changed from ui to plugin

comment:4 Changed 4 years ago by john

  • Status changed from new to closed
  • Resolution set to duplicate

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.