Skip to content

Commit

Permalink
fix: <webview> background transparency
Browse files Browse the repository at this point in the history
  • Loading branch information
Milan Burda committed Nov 4, 2021
1 parent 98bab0c commit fdde4ef
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions shell/browser/api/electron_api_web_contents.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1415,6 +1415,12 @@ void WebContents::HandleNewRenderFrame(
if (web_preferences->IsEnabled(options::kTransparent)) {
rwhv->SetBackgroundColor(SK_ColorTRANSPARENT);
}

// <webview> background needs to be transparent
if (IsGuest()) {
web_contents()->SetPageBaseBackgroundColor(SK_ColorTRANSPARENT);
rwhv->SetBackgroundColor(SK_ColorTRANSPARENT);
}
}

if (!background_throttling_)
Expand Down

0 comments on commit fdde4ef

Please sign in to comment.