Create invisible window? - Mozilla

This is a discussion on Create invisible window? - Mozilla ; Long story short, I can call window.open() to an XUL file that displays a and works exactly like I want it, except for one trivial detail. I'd like to be able to pre-load the content to go in that browser. ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: Create invisible window?

  1. Create invisible window?

    Long story short, I can call window.open() to an XUL file that displays
    a and works exactly like I want it, except for one trivial detail.

    I'd like to be able to pre-load the content to go in that browser. The
    most straightforward way would seem to be to create the window,
    invisibly, and simply make the window visible when the user wants to see
    it, rather than actually creating it.

    I've searched, but I haven't come up with a way to "create a window,
    then toggle its visibility" instead of "call window.open() then
    window.close()".

  2. Re: Create invisible window?

    Anthony Lieuallen pisze:
    > Long story short, I can call window.open() to an XUL file that displays
    > a and works exactly like I want it, except for one trivial
    > detail.
    >
    > I'd like to be able to pre-load the content to go in that browser. The
    > most straightforward way would seem to be to create the window,
    > invisibly, and simply make the window visible when the user wants to see
    > it, rather than actually creating it.
    >
    > I've searched, but I haven't come up with a way to "create a window,
    > then toggle its visibility" instead of "call window.open() then
    > window.close()".


    Try zero width and/or height.

    Or simply set Visibility ion CSS.

    --
    Arivald

  3. Re: Create invisible window?

    On 4/4/2008 10:56 AM, Arivald wrote:
    >> I've searched, but I haven't come up with a way to "create a window,
    >> then toggle its visibility" instead of "call window.open() then
    >> window.close()".

    > Try zero width and/or height.


    This requires me to keep track of the right size, to set that to
    re-display the window. And, passing 0s into the window.open options
    does not work. But opening, and then using resizeTo() does work to hide
    the window. It's sub optimal, but works for now. Thanks. Testing it
    out to double check before saying "I already tried that!" got me to find
    the call after create.

+ Reply to Thread