lewisje / svgweb

Automatically exported from code.google.com/p/svgweb
Other
0 stars 0 forks source link

Exception if remove event listener from detached element, then add to document #528

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
foo=createElement(svgns, 'rect');
foo.addEventListener('mouseover', f, false);
foo.removeEventListener('mouseover',f,false);
svgRoot.appendChild(foo)

What is the expected output? What do you see instead?
This throws an exception: 'addMe' is null or not an object

The problem is that after the event listener is deleted, the list entry is 
replaced with undefined, but the code later that adds the event listeners does 
not check to make sure the listener is still there.

Original issue reported on code.google.com by grick23@gmail.com on 30 Jun 2010 at 2:58

GoogleCodeExporter commented 8 years ago
Fixed in r1204.

Original comment by grick23@gmail.com on 2 Jul 2010 at 3:50