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
document.open() should remove the initial about:blank-ness of the document #4546
document.open() should remove the initial about:blank-ness of the document #4546
Conversation
EWS run on previous version of this PR (hash 1bb4005) |
Source/WebCore/dom/Document.cpp
Outdated
if (m_frame) | ||
if (m_frame) { | ||
// Calling window.open() counts as committing the first real document load. | ||
WTFLogAlways("CHRIS: state was %u", (unsigned)m_frame->loader().stateMachine().stateForDebugging()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably do not want those logs
Source/WebCore/dom/Document.cpp
Outdated
@@ -3043,8 +3043,16 @@ ExceptionOr<void> Document::open(Document* entryDocument) | |||
if (ScriptableDocumentParser* parser = scriptableDocumentParser()) | |||
parser->setWasCreatedByScript(true); | |||
|
|||
if (m_frame) | |||
if (m_frame) { | |||
// Calling window.open() counts as committing the first real document load. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add a pointer to the spec, either here or in commit message
1bb4005
to
b4022bc
Compare
EWS run on previous version of this PR (hash b4022bc) |
Source/WebCore/dom/Document.cpp
Outdated
if (m_frame) { | ||
// Set document's is initial about:blank to false. | ||
// https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#document-open-steps (step 13) | ||
if (m_frame->loader().stateMachine().committingFirstRealLoad()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like maybe it should be a FrameLoader
function.
b4022bc
to
b123149
Compare
EWS run on current version of this PR (hash b123149) |
β¦ument https://bugs.webkit.org/show_bug.cgi?id=245445 Reviewed by Darin Adler and Youenn Fablet. document.open() should remove the initial about:blank-ness of the document. This aligns our behavior with Firefox and Chrome. * LayoutTests/imported/w3c/web-platform-tests/html/webappapis/dynamic-markup-insertion/opening-the-input-stream/remove-initial-about-blankness.window-expected.txt: * Source/WebCore/dom/Document.cpp: (WebCore::Document::open): Canonical link: https://commits.webkit.org/254747@main
b123149
to
dc6d5ef
Compare
Committed 254747@main (dc6d5ef): https://commits.webkit.org/254747@main Reviewed commits have been landed. Closing PR #4546 and removing active labels. |
dc6d5ef
b123149
π mac-debugπ tvπ tv-simπ watchπ watch-sim