Wednesday, November 21, 2007

Firefox3 has a problem.

"xul-overlay-merged observer is notified before script elements within the overlay are processed"

Well, I guess this could be a work around.

In the <overlay id=...>, we should have <prefpane id=... onpaneload="myInit();">.
So after something like '<script type="application/x-javascript" src="chrome://..." />, 

we use

    <script type="application/x-javascript">
    // UI-specific code
        setTimeout(function () {/*whatever*/},100);

Just the onpaneload has no use here.

1 comment:

Anonymous said...

A very creative idea!

I was always facing problems using Firefox's preference system. Sometimes 'onpaneload' fires somtimes it doesn't. Absolutely annoying.

Your workaround is perfectly fixing this problem. Extension writing is fun again.

Thanks a lot for sharing.