fix: requestFullscreen
from WebContentsView
(#41995)
fix: requestFullscreen from WebContentsView Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com> Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
This commit is contained in:
parent
844265303c
commit
ec4ffa99b6
2 changed files with 15 additions and 0 deletions
|
@ -89,6 +89,9 @@ void WebContentsView::OnViewAddedToWidget(views::View* observed_view) {
|
|||
widget->GetNativeWindowProperty(electron::kElectronNativeWindowKey));
|
||||
if (!native_window)
|
||||
return;
|
||||
// We don't need to call SetOwnerWindow(nullptr) in OnViewRemovedFromWidget
|
||||
// because that's handled in the WebContents dtor called prior.
|
||||
api_web_contents_->SetOwnerWindow(native_window);
|
||||
native_window->AddDraggableRegionProvider(this);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue