From 10ed5da32565e48df0f429695416127b3007c0de Mon Sep 17 00:00:00 2001 From: Tomaz Canabrava Date: Thu, 17 Jul 2014 21:25:57 -0300 Subject: Close the print dialog after a sucessfull print I think it's intuitive to do not warn if everything was according to the plan, and keep the dialog open after a print was due is something that I find it strange. Signed-off-by: Tomaz Canabrava Signed-off-by: Dirk Hohndel --- qt-ui/printdialog.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/qt-ui/printdialog.cpp b/qt-ui/printdialog.cpp index 488afb55d..8f1a5ca68 100644 --- a/qt-ui/printdialog.cpp +++ b/qt-ui/printdialog.cpp @@ -75,8 +75,10 @@ void PrintDialog::previewClicked(void) void PrintDialog::printClicked(void) { QPrintDialog printDialog(&printer, this); - if (printDialog.exec() == QDialog::Accepted) + if (printDialog.exec() == QDialog::Accepted){ printLayout->print(); + close(); + } } void PrintDialog::onPaintRequested(QPrinter *printerPtr) -- cgit v1.2.3-70-g09d2