Nope, still there.

I debugged down into the prototype.js file and it appears that this
line is where it is getting hung up:

var wrapper = findWrapper(id, eventName, handler);
if (!wrapper) return element;

findWrapper returns null and thus detachElement/removeEventListener
never get called.

On Sep 24, 4:30 pm, "T.J. Crowder" <[EMAIL PROTECTED]> wrote:
> Hi,
>
> As you say, that suggests there's a problem somewhere else that's
> having a knock-on effect.
>
> Just for fits and giggles, what happens if you change this:
>
>     LightBox.prototype.okClick = function(){
>             this.closeBox();
>     };
>
> ...to this:
>
>     LightBox.prototype.okClick = function(){
>             var t;
>
>             t = this;
>             (function() {
>                 t.closeBox();
>             }).defer();
>     };
>
> ?  Basically what that does is wait to do the stopObserving call until
> after the event handler has completed.
> --
> T.J. Crowder
> tj / crowder software / com
>
> On Sep 24, 9:24 pm, FigglesKoy <[EMAIL PROTECTED]> wrote:
>
> > I tried copying a large chunk of the code to a separate file but I
> > can't seem to reproduce the issue outside of the main application.
> > Which I know, implies there's something wrong in my app elsewhere.  I
> > just have no idea where to look.
>
> > Seeing this on ie6/7, the application is currently not supported on
> > other browsers.
>
> > On Sep 24, 11:56 am, "T.J. Crowder" <[EMAIL PROTECTED]> wrote:
>
> > > Hi,
>
> > > Very strange.  Can you produce a minimal one-page example that
> > > demonstrates the problem?  The code looks fine.
>
> > > HTH,
> > > --
> > > T.J. Crowder
> > > tj / crowder software / com
>
> > > On Sep 24, 3:25 pm, FigglesKoy <[EMAIL PROTECTED]> wrote:
>
> > > > > Not sure what version it was introduced in, but the latest of
> > > > > Prototype allows you to call stopObserving on just the element(which
> > > > > will remove all handlers for that element)
>
> > > > Yes that is what I was expecting it to do, I'm running the latest
> > > > version of Prototype 1.6.0.2
>
> > > > > So I would make sure you are using the latest version of Prototype and
> > > > > if so then I would make sure that your stopObserving call is actually
> > > > > being invoked on the elements you expect it to. This small example
> > > > > worked for me...
>
> > > > > <html>
> > > > >   <head>
> > > > >     <title>test</title>
> > > > >   </head>
> > > > >   <body>
> > > > >     <input type="button" value="click me">
>
> > > > >     <script type="text/javascript" src="http://ajax.googleapis.com/
> > > > > ajax/libs/prototype/1.6.0.2/prototype.js"></script>
>
> > > > >     <script type="text/javascript">
> > > > >       var clicked = function() {
> > > > >         alert('hi');
> > > > >         $$('input').invoke('stopObserving');
> > > > >       }
>
> > > > >       $$('input')[0].observe('click', clicked);
> > > > >     </script>
> > > > >   </body>
> > > > > </html>
>
> > > > Not sure how this is any different than what I'm already doing.  I
> > > > tried with both an invoke() call as well as doing it manually with
> > > > this.okBtn.stopObserving() and neither worked.
>
> > > > > Just curious...how do you know that the OK button will alert if you
> > > > > removed the parent with this.lbElm.remove();? Isn't the OK button gone
> > > > > at that point?
>
> > > > Yes, you are correct, I had those lines commented out during my
> > > > testing.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to