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

Unified Diff: third_party/WebKit/Source/web/WebLocalFrameImpl.cpp

Issue 2848823005: Clear the PrintContext in WebLocalFrameImpl::Close(). (Closed)
Patch Set: ScopedPrintContext Created 3 years, 8 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
« no previous file with comments | « third_party/WebKit/Source/core/page/PrintContextTest.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp b/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
index 0b60b716c9075a1f5f5e6b9e1e5638ce6493ce88..cfa2373a385a384765e65b9525e3aa602c48a0c7 100644
--- a/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
+++ b/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
@@ -274,7 +274,7 @@ class ChromePrintContext : public PrintContext {
WTF_MAKE_NONCOPYABLE(ChromePrintContext);
public:
- ChromePrintContext(LocalFrame* frame)
+ explicit ChromePrintContext(LocalFrame* frame)
: PrintContext(frame), printed_page_width_(0) {}
~ChromePrintContext() override {}
@@ -555,6 +555,9 @@ void WebLocalFrameImpl::Close() {
dev_tools_agent_.Clear();
self_keep_alive_.Clear();
+
+ if (print_context_)
+ PrintEnd();
}
WebString WebLocalFrameImpl::AssignedName() const {
« no previous file with comments | « third_party/WebKit/Source/core/page/PrintContextTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698