diff options
author | thestig@chromium.org <thestig@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-19 15:38:08 +0000 |
---|---|---|
committer | thestig@chromium.org <thestig@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-19 15:38:08 +0000 |
commit | f5385e64e92cbd7f4afa670a4bb3abff3647ddde (patch) | |
tree | c0bb5ec6dd3421c14e5258990a9bc900f5923e30 /chrome/browser/printing/printer_query.h | |
parent | c41003476ce57ae410821397bedc90310d3dc37b (diff) | |
download | chromium_src-f5385e64e92cbd7f4afa670a4bb3abff3647ddde.zip chromium_src-f5385e64e92cbd7f4afa670a4bb3abff3647ddde.tar.gz chromium_src-f5385e64e92cbd7f4afa670a4bb3abff3647ddde.tar.bz2 |
Printing: Keep track of WebContents lifetime for the native printing UI.
BUG=305368
Review URL: https://codereview.chromium.org/27451002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@229566 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/printing/printer_query.h')
-rw-r--r-- | chrome/browser/printing/printer_query.h | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/chrome/browser/printing/printer_query.h b/chrome/browser/printing/printer_query.h index 3256a91..aab4914 100644 --- a/chrome/browser/printing/printer_query.h +++ b/chrome/browser/printing/printer_query.h @@ -10,7 +10,8 @@ #include "base/memory/scoped_ptr.h" #include "chrome/browser/printing/print_job_worker_owner.h" #include "printing/print_job_constants.h" -#include "ui/gfx/native_widget_types.h" + +class PrintingUIWebContentsObserver; namespace base { class DictionaryValue; @@ -19,8 +20,8 @@ class MessageLoop; namespace printing { - class PrintDestinationInterface; - class PrintJobWorker; +class PrintDestinationInterface; +class PrintJobWorker; // Query the printer for settings. class PrinterQuery : public PrintJobWorkerOwner { @@ -42,15 +43,16 @@ class PrinterQuery : public PrintJobWorkerOwner { virtual int cookie() const OVERRIDE; // Initializes the printing context. It is fine to call this function multiple - // times to reinitialize the settings. |parent_view| parameter's window will - // be the owner of the print setting dialog box. It is unused when + // times to reinitialize the settings. |web_contents_observer| can be queried + // to find the owner of the print setting dialog box. It is unused when // |ask_for_user_settings| is DEFAULTS. - void GetSettings(GetSettingsAskParam ask_user_for_settings, - gfx::NativeView parent_view, - int expected_page_count, - bool has_selection, - MarginType margin_type, - const base::Closure& callback); + void GetSettings( + GetSettingsAskParam ask_user_for_settings, + scoped_ptr<PrintingUIWebContentsObserver> web_contents_observer, + int expected_page_count, + bool has_selection, + MarginType margin_type, + const base::Closure& callback); // Updates the current settings with |new_settings| dictionary values. void SetSettings(const base::DictionaryValue& new_settings, |