Sidebar DOM not loaded yet - Mozilla

This is a discussion on Sidebar DOM not loaded yet - Mozilla ; There seems to be a lag after opening a sidebar with "toggleSidebar()". I cant reference the sidebar dom immediately after calling the toggle function. Could anyone suggest an asynchronous method? Thanks....

+ Reply to Thread
Results 1 to 2 of 2

Thread: Sidebar DOM not loaded yet

  1. Sidebar DOM not loaded yet

    There seems to be a lag after opening a sidebar with
    "toggleSidebar()". I cant reference the sidebar dom immediately after
    calling the toggle function. Could anyone suggest an asynchronous
    method?

    Thanks.


  2. Re: Sidebar DOM not loaded yet

    dsteinbach77@gmail.com wrote:
    > There seems to be a lag after opening a sidebar with
    > "toggleSidebar()". I cant reference the sidebar dom immediately after
    > calling the toggle function. Could anyone suggest an asynchronous
    > method?
    >
    > Thanks.
    >


    The sidebar is a . Like any other , you need to wait
    for the load event (addEventListener). This is similiar to looking at
    things in the main content area when the window opens. (You did have to
    use .contentDocument to see the DOM, right?)

    HTH,

    --
    Mook
    mook dot moz plus stuff at gmail

+ Reply to Thread