Closed Bug 1449992 Opened 7 years ago Closed 6 years ago

consider reusing the inner window for document.open()

Categories

(Core :: DOM: Core & HTML, enhancement, P3)

enhancement

Tracking

()

RESOLVED FIXED

People

(Reporter: bkelly, Unassigned)

References

Details

Currently we create a new inner window when document.open() is called. This follows the spec, but we are the only browser that implements this behavior. In addition, we have at least one test that seems to expect DOM objects parented to the old inner window to continue functioning after document.open(): https://searchfox.org/mozilla-central/rev/7e663b9fa578d425684ce2560e5fa2464f504b34/dom/base/test/test_bug372964-2.html In bug 1447871 I am re-binding DETH objects to the new inner window to keep this working. It would be easier to explain, however, if the original inner window was simply reused.
This would need a clear description of what happens instead, then. It would also need a definition of how this interacts with session history.
As far as I can tell it doesn't. https://cs.chromium.org/chromium/src/third_party/WebKit/Source/core/dom/Document.cpp?q=Document.cpp&sq=package:chromium&dr&l=2902 ends up resetting a couple of things (selection, event listeners, children, parser) and that's pretty much it. I'm planning to write more tests for all this, but most of it looks pretty straightforward.
> As far as I can tell it doesn't Right, that's the problem.
See Also: → 1453721
Priority: -- → P3
Depends on: 1489308

Fixed by bug 1489308.

Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.