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"
@@ -496,6 +497,15 @@ void NativeWindowAura::SetTransparent(bool transparent) {
496
497
toolbar_->SchedulePaint ();
497
498
}
498
499
500
+ // this is needed to prevent white popup on startup
501
+ content::RenderWidgetHostView* rwhv = shell_->web_contents ()->GetRenderWidgetHostView ();
502
+ if (rwhv) {
503
+ if (transparent)
504
+ rwhv->SetBackgroundColor (SK_ColorTRANSPARENT);
505
+ else
506
+ rwhv->SetBackgroundColorToDefault ();
507
+ }
508
+
499
509
content::RenderViewHostImpl* rvh = static_cast <content::RenderViewHostImpl*>(shell_->web_contents ()->GetRenderViewHost ());
500
510
if (rvh) {
501
511
rvh->SetBackgroundOpaque (!transparent);
You can’t perform that action at this time.
0 commit comments