added checks for painting_ when setting the outputdevice to active state and removed show/hide from start/stoppainting since during testing they caused transparent frames to appear when a window was set to paint again after stopping

This commit is contained in:
Heilig Benedek 2016-08-05 04:35:04 +02:00
parent 3be68ba136
commit 29f30aa6ba
4 changed files with 5 additions and 15 deletions

View file

@ -1354,10 +1354,8 @@ void WebContents::StartPainting() {
auto* osr_rwhv = static_cast<OffScreenRenderWidgetHostView*>(
web_contents()->GetRenderWidgetHostView());
if (osr_rwhv) {
osr_rwhv->Show();
if (osr_rwhv)
osr_rwhv->SetPainting(true);
}
}
void WebContents::StopPainting() {
@ -1366,10 +1364,8 @@ void WebContents::StopPainting() {
auto* osr_rwhv = static_cast<OffScreenRenderWidgetHostView*>(
web_contents()->GetRenderWidgetHostView());
if (osr_rwhv) {
if (osr_rwhv)
osr_rwhv->SetPainting(false);
osr_rwhv->Hide();
}
}
bool WebContents::IsPainting() const {