Skip to content

iframe.goBack() doesn't paint the previous pipeline #9919

Closed

Description

@paulrouget

STR:

  • load test case (see "foo")
  • click on "go to next page" (see "bar")
  • click on goBack

"foo" should show up.

<!-- dom.mozbrowser.enabled needed -->
<iframe style="display:block;width:300px;height:300px" mozbrowser="true" src="data:,foo"></iframe>
<button onclick="f.src = 'data:,bar'">go to next page</button>
<button onclick="f.goBack()">goBack</button>
<button onclick="f.goForward()">goForward</button>
<script>
  var f = document.querySelector("iframe");
</script>

Activity

  1. self-assigned this
    on Mar 8, 2016
  2. added
    C-assigned
    on Mar 8, 2016
  3. paulrouget commented on Mar 15, 2016

    @paulrouget
    ContributorAuthor

    So first, I think we revoke paint permission of the wrong pipeline:

    // Revoke paint permission from a pipeline, and all children.

    Here we traverse the frame tree, but the top level frame of that tree should not use pipeline(frame.current) but pipeline(pipeline_id). Or, revoke_paint_permission should be called before the new pipeline is set to frame.current.

    But that's apparently not enough.

    The right frame tree is sent to the compositor. Paint permissions appear to be properly set.

    With WR, the old page is not replace by the new one.
    Without WR, the new page is replaced by a blank page.

  4. jdm commented on Mar 15, 2016

    @jdm
    Member
  5. glennw commented on Mar 15, 2016

    @glennw
    Member

    @paulrouget I'm not sure I understand what's wrong with that code. On the first iteration through that loop, pipeline_id should be equal to frame.current - is it not? From there it should loop through any iframes in the free tree from that root. The iframe goBack() code certainly used to work and I don't think that part has changed for quite some time, so I suspect a regression elsewhere.

  6. paulrouget commented on Mar 15, 2016

    @paulrouget
    ContributorAuthor

    On the first iteration through that loop, pipeline_id should be equal to frame.current - is it not?

    If I understand correctly how this works, it is not.

    frame.current is set to next (which is correct), and then we call revoke_paint_permission(prev) (which is correct), but within revoke_paint_permission, we use frame.current.

  7. paulrouget commented on Mar 15, 2016

    @paulrouget
    ContributorAuthor

    regression: c72d0c2

  8. paulrouget commented on Mar 15, 2016

    @paulrouget
    ContributorAuthor

    @pcwalton any idea what might have gone wrong with c72d0c2?

    Also - related (fixed) issue: #8081

  9. removed their assignment
    on Mar 16, 2016
  10. added
    C-looking for assistance
    and removed
    C-assigned
    on Mar 16, 2016
  11. added 3 commits that reference this issue on Mar 24, 2016
    82cac09
    dd97a10
    e5287b4
  12. pcwalton commented on Mar 24, 2016

    @pcwalton
    Contributor

    @paulrouget Should be fixed by #10159.

  13. paulrouget commented on Mar 24, 2016

    @paulrouget
    ContributorAuthor

    follow up for the revoke_paint_permission thing: #10162

  14. added a commit that references this issue on Mar 24, 2016
    eb6a9bd
  15. pcwalton commented on Mar 28, 2016

    @pcwalton
    Contributor

    Can we close this in favor of #10162, in the absence of known actual browser.html problems this is causing?

  16. paulrouget commented on Mar 29, 2016

    @paulrouget
    ContributorAuthor

    So this is fixed.

    #10162 doesn't cause any bug afaict. Just thought I filed it just in case.

  17. paulrouget commented on Mar 29, 2016

    @paulrouget
    ContributorAuthor

    Sorry, not fixed, I though #10159 landed.

  18. pcwalton commented on Mar 29, 2016

    @pcwalton
    Contributor

    Oh right, sorry about that.

  19. added a commit that references this issue on Apr 1, 2016
    5308e8c
  20. added a commit that references this issue on Apr 1, 2016
    c8e71cf
  21. added a commit that references this issue on Apr 28, 2016
    7bd2570
  22. added a commit that references this issue on Apr 28, 2016
    3836c2c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-looking for assistance

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions