Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Selecting/adding overlay works - but not displayed (PixelPerfect 2.0.1) #52

Open
neufeind opened this issue Sep 9, 2012 · 1 comment

Comments

@neufeind
Copy link

neufeind commented Sep 9, 2012

I notied that for Firebug 1.10.x there were already fixes added quite some time ago. And in the dist-folder there is is build 2.0.1 available. I tried that out and that seems to make it work with the newer Firebug-API (ability to add an overlay, ...). Using Firebug itself then I can also see that the pp_overlay is added to the HTML etc. but the image doesn't display. Giving that overlay a background-color shows that it's position correctly etc. And the background-image displays as a thumbnail in Firebug (when hovering over the CSS-code) as well. It's just that Firefox doens't want to display it as defined via CSS in property "background". Maybe some security-thing because that image is loaded via a chrome-URL?

Using Firefox 15.0 and Firebug 1.10.3 here.

@killerog
Copy link

killerog commented Dec 9, 2012

Hey people,

I really miss this add-on and spend lot's of hours searching this weekend where the problem is. Now I only have a little experience with firefox add-on but I think I have isolated the problem to this bit of code around line 90 of PixelPerfectUtilsModule.js

    //FIXME: Make sure js element does not already exist to avoid duplicates
    loadRequiredJsIntoToMainBrowserOverlay: function() {
        var doc = window._content.document;
        var pageHead = doc.getElementsByTagName("head")[0];
        var scripts = ['dom-drag.js', 'publicDocumentEvents.js'];
        for(i=0; i<scripts.length; i++) {
            pageHead.appendChild(this.createJsElement('chrome://pixelperfect/content/browserscripts/' + scripts[i], doc));
        }
    }

First off the _content seems to be deprecated, but even then if you try to get the url of the window it always passes along about:blank in my case. So I think the script is just inserted too early.

If you try to debug the add-on you see it gives an error on the not existing of the Drag object in the page.

Have been trying different things to fix it, but I am not closer to a solution. So I thought to just share it, maybe there's another programmer around who sees the solution directly :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants