diff options
author | John Layt <jlayt@kde.org> | 2014-03-24 18:53:06 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-04-05 21:48:03 +0200 |
commit | 39c5098dbb3dd547c315c5baf0f83ebe81b28756 (patch) | |
tree | 9dbbe5d87d4d82e594ef6385671d3e513ad10c8c /tests/manual/dialogs/printdialogpanel.cpp | |
parent | bc46b591b2cb81a5cb0c513aa4139b7e88fa8b06 (diff) |
QPrintDialog - Add Direct print to manual test
Enable printing without dialog.
Change-Id: I1058361febc7ddd8a5e0471e4365969e2f8becfe
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Diffstat (limited to 'tests/manual/dialogs/printdialogpanel.cpp')
-rw-r--r-- | tests/manual/dialogs/printdialogpanel.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/manual/dialogs/printdialogpanel.cpp b/tests/manual/dialogs/printdialogpanel.cpp index f7d027020c..1a18f94406 100644 --- a/tests/manual/dialogs/printdialogpanel.cpp +++ b/tests/manual/dialogs/printdialogpanel.cpp @@ -379,6 +379,7 @@ PrintDialogPanel::PrintDialogPanel(QWidget *parent) connect(m_panel.m_printButton, SIGNAL(clicked()), this, SLOT(showPrintDialog())); connect(m_panel.m_printPreviewButton, SIGNAL(clicked()), this, SLOT(showPreviewDialog())); connect(m_panel.m_pageSetupButton, SIGNAL(clicked()), this, SLOT(showPageSetupDialog())); + connect(m_panel.m_directPrintButton, SIGNAL(clicked()), this, SLOT(directPrint())); enablePanels(); m_blockSignals = false; @@ -686,6 +687,13 @@ void PrintDialogPanel::showPageSetupDialog() retrieveSettings(m_printer.data()); } +void PrintDialogPanel::directPrint() +{ + applySettings(m_printer.data()); + print(m_printer.data()); + retrieveSettings(m_printer.data()); +} + #include "moc_printdialogpanel.cpp" #include "printdialogpanel.moc" |