Closed Bug 469898 Opened 16 years ago Closed 16 years ago

xbl binding not loading from resource://

Categories

(Core :: XBL, defect)

x86
Linux
defect
Not set
minor

Tracking

()

RESOLVED WONTFIX

People

(Reporter: cseickel, Unassigned)

References

Details

Attachments

(1 file)

User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1b2) Gecko/20081201 Firefox/3.1b2 Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1b2) Gecko/20081201 Firefox/3.1b2 It worked fine on firefox 3.0.x, but xbl bindings will not load from a resource:// url in 3.2 beta 2. When I copied the xbl files into the content directory and updated the urls to the chrome:// url, it worked fine. This issue can be seen on the alpha of Music Player Minion 2: http://musicpm.googlecode.com/files/mpm_1.99.12.xpi Tested on Ubuntu 8.10, and the xbl files load properly using the same urls in the address bar. Also, js modules load and run from the same resource directory. No errors are reported, the bindings are just ignored. chrome.manifest: content minion chrome/content/ resource minion chrome/resource/ Original css: mpdlabel { -moz-binding: url("resource://minion/mpdControls.xml#mpdLabel") } After files are copied to content directory, it works as: mpdlabel { -moz-binding: url("chrome://minion/content/mpdControls.xml#mpdLabel") } Reproducible: Always Steps to Reproduce: 1. Install Music Player Minion 1.99.12 from http://musicpm.googlecode.com/files/mpm_1.99.12.xpi 2. Click on folder icon to load page (only surviving icon, the rest are xbl). 3. Notice the half complete application. All xbl widgets are missing. Actual Results: All xbl bound nodes are not loaded. Expected Results: Bind to xbl loaded from resource://minion/ As suggested by Boris Zbarsky, I will test against the nightlies and report back the current result and if I can find where it broke.
I tested the nightly builds to see where this bug started. It showed up between November 13 and November 14. I attached the log I used when testing.
Chris, thanks for doing that! Changes made in that date range (+2 hours on each side): http://hg.mozilla.org/mozilla-central/pushloghtml?startdate=2008-11-13+00&enddate=2008-11-14+04 The only thing in that range that looks like it might be a problem here is bug 425153. In a current build, I get the following errors in the error console: Error: document.getElementById("popup_playlist") is null Source File: chrome://minion/content/browser_overlay.xul Line: 169 Error: uncaught exception: [Exception... "Could not convert JavaScript argument" nsresult: "0x80570009 (NS_ERROR_XPC_BAD_CONVERT_JS)" location: "JS frame :: chrome://minion/content/browser_overlay.xul :: anonymous :: line 48" data: no] Are those what you're seeing? Are you seeing something else? Where is the folder icon I'm supposed to click?
The errors are side effects of the xbl not loading. I went xbl happy on this and built most of the functionality into xbl widgets. The folder icon should be in the statusbar on the far right. You can also just load chrome://minion/content/minion.xul To see how it should look, you can copy the xbl files from resource into the chrome/content directory and change all of the resource://minion/ urls in content/bindings.css to be chrome://minion/content/
BTW - I don't have access to view bug 425153, did it have something to do with security on resource urls?
It had to do with security of chrome loading non-chrome scripts, since those scripts wouldn't be protected in the same ways as chrome ones in some cases. And in fact, there is an explicit check there to prevent XBL from non-chrome sources being loaded into a chrome document. See bug 425153 comment 19. I've cced you on the bug so you can read it. I think this is wontfix given the issues in that bug. :( That bug does have dev-doc-needed, so presumably we'll document this before ship....
Blocks: 425153
Status: UNCONFIRMED → RESOLVED
Closed: 16 years ago
Resolution: --- → WONTFIX
Sounds good, not a big deal to just switch over to chrome. At least now it's documented in bugzilla, hopefully it gets noted in the dev docs. Thanks a lot for your help! I really appreciate the work that you do.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: