Okay, this is really odd.
After adding the logging in both lib.$ and chrome.$ in the firebug
code, I found something really odd. When firebug is inside firefox,
everything is cool and the global "$" as seen by chrome.$ is the same
as FBL.$, but when I open firebug in a window, I get a different "$"
in chrome.js.
I changed the $ function in chrome.$ to this:
$: function(id)
{
FBTrace.sysout("chrome.$ document: "+(document.location) + " for ID: "
+ id + " and $ is: " + $ + " FBL.$ = " + FBL.$);
return $(id);
},
And $ in lib.js to this:
this.$ = function(id, doc)
{
FBTrace.sysout("lib.$ document: "+(doc?
doc.location:document.location) + " for ID: " + id);
if (doc)
return doc.getElementById(id);
else
return document.getElementById(id);
};
But when I have firebug in its own window I see this output in the
console:
FTS0: chrome.$ document: chrome://firebug/content/firebug.xul for ID:
fbAdfvTypeMenu and $ is: function $(id, doc) {
if (doc) {
return doc.getElementById(id);
} else {
return document.getElementById(id);
}
} FBL.$ = function (id, doc) {
FBTrace.sysout("lib.$ document: " + (doc ? doc.location :
document.location) + " for ID: " + id);
if (doc) {
return doc.getElementById(id);
} else {
return document.getElementById(id);
}
}
As you can see, the global "$" function is different than "FBL.$"
function. I tried disabling all my extensions except for firebug and
mine, and so far I do not see who is overwriting the "$" in chrome's
namespace or window object. Quite odd. Don't suppose you know what is
going on?
If it matters, I am using firefox 3.5.3 shipped by Ubuntu in Jaunty
and Firebug 1.4.3
Thanks for all your help.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Firebug" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/firebug?hl=en
-~----------~----~----~----~------~----~------~--~---