-
Notifications
You must be signed in to change notification settings - Fork 15k
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
feat: Allow WebContentsView to accept webContents object. #42086
feat: Allow WebContentsView to accept webContents object. #42086
Conversation
07cc3ac
to
bcf4199
Compare
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.
API LGTM
if (existing_web_contents->owner_window() != nullptr) { | ||
args->ThrowError( | ||
"options.webContents is already attached to a window"); | ||
return nullptr; | ||
} | ||
} |
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.
nit: It'd be preferred to move this check inside of the block on line 182
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.
API LGTM
Release Notes Persisted
|
I have automatically backported this PR to "31-x-y", please check out #42319 |
Description of Change
Closes #42054.
This PR enables
WebContentsView
to accept existingwebContents
object in order to be able to properly handle popups. This issue is described here: #42054.Checklist
npm test
passesRelease Notes
Notes: Extended
WebContentsView
to accept pre-existingwebContents
object.