i came up with this very ham-fisted fix that is at least going to
allow me to say that i got more finished today than staring emptily at
the screen:

        function makeMenubar(w,wid,c) {
                var menu = $("##"+w+"Header");
                menu.append("<a class='close' id='"+w+"_close'/>");
                menu.append("<div class='menubutton' 
id='"+w+"_menubutton'></div>");
                var jq = $;
                $("##"+w+"_menubutton").click(function(e) {
                        $.extend(jq);
                        fileMenu(w,e.clientX,e.clientY,c);
                });
                $("##"+w+"_close").click(function() {closeWidget(wid,w);});
        }

it seems like a really cheesy way to get the thing working, but it
does add all the missing functionality back into the jquery object.
i'd like to understand the "right" way to fix the problem, because the
way i've got it doesn't really make me comfortable.

--adam

On Feb 1, 3:16 pm, ajpiano <[EMAIL PROTECTED]> wrote:
> pardon my amateurishness, but i can't quite grasp the consequences of
> that fact for solving my issue.  the makeMenubar function is indeed
> being called inside of $(el).each(), but i don't really know why the
> plugins would drop out of jQuery as a result of this scoping problem.
> i must be so brash as to request a more verbose explanation if such
> can be provided.
>
> thanks
>
> --adam
>
> On Feb 1, 2:57 pm, "Sean Catchpole" <[EMAIL PROTECTED]> wrote:
>
> > var mb3 = $(this);
> > On that line, the this is referring to the scope of the function which is
> > not inside of an $.each(..) or $.fn.foo(..)
>
> > ~Sean

Reply via email to