Re: Error on startup when registering content policy from bootstrapped extension

2013-05-13 Thread Neil
Matthew Gertner wrote: On Sunday, May 12, 2013 5:54:04 PM UTC+2, Neil wrote: browsers don't load documents, doc shells do. So, my question is again, where's the doc shell that's loading the about:blank? Ah, I see your point. Maybe it's there but not associated with the boxobject yet?

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-13 Thread Matthew Gertner
On Sunday, May 12, 2013 5:54:04 PM UTC+2, Neil wrote: > browsers don't load documents, doc shells do. So, my question is again, > where's the doc shell that's loading the about:blank? Ah, I see your point. Maybe it's there but not associated with the boxobject yet? __

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-12 Thread Neil
Matthew Gertner wrote: On Sunday, May 12, 2013 12:25:59 AM UTC+2, Neil wrote: But the original error was that the webNavigation was null... so what's loading the about:blank in the first place? about:blank is being loaded because the browser is starting up and restoring the old sessi

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-12 Thread Matthew Gertner
On Sunday, May 12, 2013 12:25:59 AM UTC+2, Neil wrote: > But the original error was that the webNavigation was null... so what's > loading the about:blank in the first place? about:blank is being loaded because the browser is starting up and restoring the old session. As I understand it, the con

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-11 Thread Neil
Gavin Sharp wrote: I believe bz's theory is that the 's binding was being force-applied because the was being wrapped to be passed to your JS-implemented content policy (as aContext). But the original error was that the webNavigation was null... so what's loading the about:blank in the firs

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-11 Thread Matthew Gertner
https://bugzilla.mozilla.org/show_bug.cgi?id=871176 ___ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-11 Thread Gavin Sharp
I suppose you could say it's a bug in the browser binding. Worth filing, CC me? Gavin On Sat, May 11, 2013 at 2:26 PM, Matthew Gertner wrote: > On Saturday, May 11, 2013 7:37:00 PM UTC+2, Gavin Sharp wrote: >> I believe bz's theory is that the 's binding was being >> force-applied because the w

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-11 Thread Matthew Gertner
On Saturday, May 11, 2013 7:37:00 PM UTC+2, Gavin Sharp wrote: > I believe bz's theory is that the 's binding was being > force-applied because the was being wrapped to be passed to > your JS-implemented content policy (as aContext). XBL bindings are > force-applied when an element in a document i

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-11 Thread Gavin Sharp
I believe bz's theory is that the 's binding was being force-applied because the was being wrapped to be passed to your JS-implemented content policy (as aContext). XBL bindings are force-applied when an element in a document is JS-wrapped and its binding hasn't yet been applied through normal mec

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-11 Thread Matthew Gertner
On Saturday, May 11, 2013 11:29:58 AM UTC+2, Matthew Gertner wrote: > Just before the error occurs, the policy is called with aRequestOrigin set to > chrome://browser/content/browser.xul and aContentLocation set to about:blank. > I just don't understand why the existence of the policy causes the

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-11 Thread Matthew Gertner
On Friday, May 10, 2013 6:15:59 PM UTC+2, Boris Zbarsky wrote: > Is your policy being called with the subject set to the ? Just before the error occurs, the policy is called with aRequestOrigin set to chrome://browser/content/browser.xul and aContentLocation set to about:blank. I just don't unde

Re: Error on startup when registering content policy from bootstrapped extension

2013-05-10 Thread Boris Zbarsky
On 5/10/13 10:55 AM, Matthew Gertner wrote: Apparently the constructor is being called before the docShell is there. I can't see why registering a category entry with type "content-policy" would cause this, however. From the code it looks like the entry just gets put into the list maintained b

Error on startup when registering content policy from bootstrapped extension

2013-05-10 Thread Matthew Gertner
I'm registering a content policy (implemented in JavaScript) from the startup() function of my bootstrap.js. When I do so, I get an error in the Error Console: Timestamp: 5/10/13 4:50:56 PM Error: this.webNavigation is null Source File: chrome://global/content/bindings/browser.xml Line: 721 Appa