fix: ensure web_contents is not nullptr in UpdateDraggableRegions (#21955)
* fix: ensure web_contents is not nullptr in UpdateDraggableRegions This is a speculative fix for a crash in `UpdateDraggableRegions` that we've noticed * Update atom_api_browser_window_mac.mm * Update atom_api_browser_window_mac.mm
This commit is contained in:
parent
2a47300d61
commit
e528029345
1 changed files with 3 additions and 0 deletions
|
@ -79,6 +79,9 @@ void BrowserWindow::UpdateDraggableRegions(
|
|||
if (window_->has_frame())
|
||||
return;
|
||||
|
||||
if (!web_contents())
|
||||
return;
|
||||
|
||||
// All ControlRegionViews should be added as children of the WebContentsView,
|
||||
// because WebContentsView will be removed and re-added when entering and
|
||||
// leaving fullscreen mode.
|
||||
|
|
Loading…
Reference in a new issue