diff options
author | thestig@chromium.org <thestig@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-24 03:28:14 +0000 |
---|---|---|
committer | thestig@chromium.org <thestig@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-24 03:28:14 +0000 |
commit | de0ca76065a44ccbce60315aca8de7803586cac8 (patch) | |
tree | 4de70c2898c7bd892fe60dd0d2b0820626c3de0e /content | |
parent | 7f4c84ffe959733ebe3fe1e6c5ea2c65a2dc218f (diff) | |
download | chromium_src-de0ca76065a44ccbce60315aca8de7803586cac8.zip chromium_src-de0ca76065a44ccbce60315aca8de7803586cac8.tar.gz chromium_src-de0ca76065a44ccbce60315aca8de7803586cac8.tar.bz2 |
Cleanup: Move TabContents::PrintPreview() to PrintPreviewTabController to remove a contents-chrome dependency.
BUG=76795
TEST=none
R=arv@chromium.org
Review URL: http://codereview.chromium.org/6675017
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@79246 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
-rw-r--r-- | content/browser/renderer_host/render_view_host.cc | 4 | ||||
-rw-r--r-- | content/browser/renderer_host/render_view_host.h | 3 | ||||
-rw-r--r-- | content/browser/tab_contents/tab_contents.cc | 16 | ||||
-rw-r--r-- | content/browser/tab_contents/tab_contents.h | 7 |
4 files changed, 0 insertions, 30 deletions
diff --git a/content/browser/renderer_host/render_view_host.cc b/content/browser/renderer_host/render_view_host.cc index b5143ae..b7a13d5 100644 --- a/content/browser/renderer_host/render_view_host.cc +++ b/content/browser/renderer_host/render_view_host.cc @@ -1232,10 +1232,6 @@ void RenderViewHost::ContextMenuClosed( Send(new ViewMsg_ContextMenuClosed(routing_id(), custom_context)); } -void RenderViewHost::PrintNodeUnderContextMenu() { - Send(new ViewMsg_PrintNodeUnderContextMenu(routing_id())); -} - void RenderViewHost::PrintForPrintPreview(const DictionaryValue& job_settings) { Send(new ViewMsg_PrintForPrintPreview(routing_id(), job_settings)); } diff --git a/content/browser/renderer_host/render_view_host.h b/content/browser/renderer_host/render_view_host.h index ba08905..3172d84 100644 --- a/content/browser/renderer_host/render_view_host.h +++ b/content/browser/renderer_host/render_view_host.h @@ -314,9 +314,6 @@ class RenderViewHost : public RenderWidgetHost { void ContextMenuClosed( const webkit_glue::CustomContextMenuContext& custom_context); - // Prints the node that's under the context menu. - void PrintNodeUnderContextMenu(); - // Triggers printing of the preview PDF. |job_settings| dictionary contains // new print job settings information. void PrintForPrintPreview(const DictionaryValue& job_settings); diff --git a/content/browser/tab_contents/tab_contents.cc b/content/browser/tab_contents/tab_contents.cc index f24f1c6..61bae0c 100644 --- a/content/browser/tab_contents/tab_contents.cc +++ b/content/browser/tab_contents/tab_contents.cc @@ -1160,22 +1160,6 @@ void TabContents::EmailPageLocation() { platform_util::OpenExternal(GURL(mailto)); } -void TabContents::PrintPreview() { - if (CommandLine::ForCurrentProcess()->HasSwitch( - switches::kEnablePrintPreview)) { - if (showing_interstitial_page()) - return; - - printing::PrintPreviewTabController* tab_controller = - printing::PrintPreviewTabController::GetInstance(); - if (!tab_controller) - return; - tab_controller->GetOrCreatePreviewTab(this, controller().window_id().id()); - } else { - PrintNow(); - } -} - bool TabContents::PrintNow() { // We can't print interstitial page for now. if (showing_interstitial_page()) diff --git a/content/browser/tab_contents/tab_contents.h b/content/browser/tab_contents/tab_contents.h index e67b822..efac700 100644 --- a/content/browser/tab_contents/tab_contents.h +++ b/content/browser/tab_contents/tab_contents.h @@ -560,13 +560,6 @@ class TabContents : public PageNavigator, // current page's URL. void EmailPageLocation(); - // Displays asynchronously a print preview (generated by the renderer) if not - // already displayed and ask the user for its preferred print settings with - // the "Print..." dialog box. (managed by the print worker thread). - // TODO(maruel): Creates a snapshot of the renderer to be used for the new - // tab for the printing facility. - void PrintPreview(); - // Prints the current document immediately. Since the rendering is // asynchronous, the actual printing will not be completed on the return of // this function. Returns false if printing is impossible at the moment. |