Skip to content
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

Can "disowned" and "opener browsing context" be collapsed? #5569

Closed
domenic opened this issue May 20, 2020 · 2 comments · Fixed by #8573
Closed

Can "disowned" and "opener browsing context" be collapsed? #5569

domenic opened this issue May 20, 2020 · 2 comments · Fixed by #8573
Labels

Comments

@domenic
Copy link
Member

domenic commented May 20, 2020

A browsing context has an opener browsing context, which is null or a browsing context. It is initially null.

A browsing context has a disowned boolean. It is initially false.

It appears that our current architecture is that if window.opener gets set to null`, then we set the BC's "disowned" to true, but we do not null out the "opener browsing context".

Could we get rid of the disowned boolean, and instead just null out the "opener browsing context"?

At least in the scope of HTML, it appears this would impact exactly one place: "familiar with", used in close() checks and in <a name="">, window.open(url, name) targeting checks. That checks only the opener browsing context, and disregards the disowning status. That is, currently per spec disowning your opener does not prevent your opener from .close()ing you or navigating you using name targeting.

The link targeting aspect of this is covered in #313, so this might largely be a duplicate of that issue. But I thought it was worth pointing out this more-editorial issue specifically.

@domenic domenic added clarification Standard could be clearer topic: browsing context labels May 20, 2020
@annevk
Copy link
Member

annevk commented May 21, 2020

Yeah, see #2636 (comment) and #313 (comment). That seems suggest merging might be possible, but someone would have to sort this out to be sure.

@annevk
Copy link
Member

annevk commented Nov 30, 2022

Doing this might help solve a bug. Currently once a browsing context is disowned it seems it can no longer become non-disowned. That seems wrong, especially across origins. But also in a normal case where you set it to null (i.e., disown). Then name target it. And now it's still null except it's not in browsers.

Chatting with @mystor suggests disowned is not really a concept browsers have. Auxiliary is though.

annevk added a commit that referenced this issue Dec 1, 2022
annevk added a commit that referenced this issue Feb 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging a pull request may close this issue.

2 participants