File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change 45
45
#include " content/public/browser/native_web_keyboard_event.h"
46
46
#include " content/public/browser/render_view_host.h"
47
47
#include " content/browser/renderer_host/render_view_host_impl.h"
48
+ #include " content/public/browser/render_widget_host_view.h"
48
49
#include " content/public/browser/web_contents.h"
49
50
#include " content/public/common/content_switches.h"
50
51
#include " extensions/common/draggable_region.h"
@@ -498,6 +499,15 @@ void NativeWindowAura::SetTransparent(bool transparent) {
498
499
toolbar_->SchedulePaint ();
499
500
}
500
501
502
+ // this is needed to prevent white popup on startup
503
+ content::RenderWidgetHostView* rwhv = shell_->web_contents ()->GetRenderWidgetHostView ();
504
+ if (rwhv) {
505
+ if (transparent)
506
+ rwhv->SetBackgroundColor (SK_ColorTRANSPARENT);
507
+ else
508
+ rwhv->SetBackgroundColorToDefault ();
509
+ }
510
+
501
511
content::RenderViewHostImpl* rvh = static_cast <content::RenderViewHostImpl*>(shell_->web_contents ()->GetRenderViewHost ());
502
512
if (rvh) {
503
513
rvh->SetBackgroundOpaque (!transparent);
You can’t perform that action at this time.
0 commit comments