| Index: chrome/renderer/printing/print_web_view_helper.cc
|
| diff --git a/chrome/renderer/printing/print_web_view_helper.cc b/chrome/renderer/printing/print_web_view_helper.cc
|
| index 201e4c25cfc9c3bcd65485912053db37fa698538..892505fe344c908c7475e28034ba4cc838712b21 100644
|
| --- a/chrome/renderer/printing/print_web_view_helper.cc
|
| +++ b/chrome/renderer/printing/print_web_view_helper.cc
|
| @@ -607,8 +607,6 @@ class PrepareFrameAndViewForPrint : public blink::WebViewClient,
|
| void RestoreSize();
|
| void CopySelection(const WebPreferences& preferences);
|
|
|
| - base::WeakPtrFactory<PrepareFrameAndViewForPrint> weak_ptr_factory_;
|
| -
|
| FrameReference frame_;
|
| blink::WebNode node_to_print_;
|
| bool owns_web_view_;
|
| @@ -621,6 +619,8 @@ class PrepareFrameAndViewForPrint : public blink::WebViewClient,
|
| bool should_print_selection_only_;
|
| bool is_printing_started_;
|
|
|
| + base::WeakPtrFactory<PrepareFrameAndViewForPrint> weak_ptr_factory_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(PrepareFrameAndViewForPrint);
|
| };
|
|
|
| @@ -629,14 +629,14 @@ PrepareFrameAndViewForPrint::PrepareFrameAndViewForPrint(
|
| blink::WebLocalFrame* frame,
|
| const blink::WebNode& node,
|
| bool ignore_css_margins)
|
| - : weak_ptr_factory_(this),
|
| - frame_(frame),
|
| + : frame_(frame),
|
| node_to_print_(node),
|
| owns_web_view_(false),
|
| expected_pages_count_(0),
|
| should_print_backgrounds_(params.should_print_backgrounds),
|
| should_print_selection_only_(params.selection_only),
|
| - is_printing_started_(false) {
|
| + is_printing_started_(false),
|
| + weak_ptr_factory_(this) {
|
| PrintMsg_Print_Params print_params = params;
|
| if (!should_print_selection_only_ ||
|
| !PrintingNodeOrPdfFrame(frame, node_to_print_)) {
|
|
|