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

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

Issue 2864753004: M59: Clear the PrintContext in WebLocalFrameImpl::Close(). (Closed)
Patch Set: fix Created 3 years, 7 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 634bd57f0045030d7d02dcd5f5ca9065a1297527..512572f3d7139c395f53b29fcb4ef397259330da 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