Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(785)

Unified Diff: components/printing/renderer/print_web_view_helper.cc

Issue 1991273003: Fire visibilityChange event on out-of-process iframes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/printing/renderer/print_web_view_helper.cc
diff --git a/components/printing/renderer/print_web_view_helper.cc b/components/printing/renderer/print_web_view_helper.cc
index fa79d1a2714353a0a665ff0e7f4c77d78738f0ea..b25340caef36cf1d0d6d13d3ea41c0c3890fda69 100644
--- a/components/printing/renderer/print_web_view_helper.cc
+++ b/components/printing/renderer/print_web_view_helper.cc
@@ -522,7 +522,8 @@ void PrintWebViewHelper::PrintHeaderAndFooter(
page_layout.margin_top + page_layout.margin_bottom +
page_layout.content_height);
- blink::WebView* web_view = blink::WebView::create(NULL);
+ blink::WebView* web_view =
+ blink::WebView::create(nullptr, blink::WebPageVisibilityStateVisible);
web_view->settings()->setJavaScriptEnabled(true);
blink::WebLocalFrame* frame =
@@ -739,7 +740,8 @@ void PrepareFrameAndViewForPrint::CopySelection(
WebPreferences prefs = preferences;
prefs.javascript_enabled = false;
- blink::WebView* web_view = blink::WebView::create(this);
+ blink::WebView* web_view =
+ blink::WebView::create(this, blink::WebPageVisibilityStateVisible);
owns_web_view_ = true;
content::RenderView::ApplyWebPreferences(prefs, web_view);
web_view->setMainFrame(
« no previous file with comments | « components/plugins/renderer/webview_plugin.cc ('k') | content/browser/frame_host/render_frame_host_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698