summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--qt-ui/printdialog.cpp3
-rw-r--r--qt-ui/printdialog.h2
2 files changed, 4 insertions, 1 deletions
diff --git a/qt-ui/printdialog.cpp b/qt-ui/printdialog.cpp
index 48c5a5619..e029ff09b 100644
--- a/qt-ui/printdialog.cpp
+++ b/qt-ui/printdialog.cpp
@@ -48,7 +48,7 @@ PrintDialog::PrintDialog(QWidget *parent, Qt::WindowFlags f)
connect(closeButton, SIGNAL(clicked(bool)), this, SLOT(closeClicked()));
hLayout->addWidget(closeButton);
- QProgressBar *progressBar = new QProgressBar();
+ progressBar = new QProgressBar();
connect(printLayout, SIGNAL(signalProgress(int)), progressBar, SLOT(setValue(int)));
progressBar->setMinimum(0);
progressBar->setMaximum(100);
@@ -64,6 +64,7 @@ PrintDialog::PrintDialog(QWidget *parent, Qt::WindowFlags f)
void PrintDialog::runDialog()
{
+ progressBar->setValue(0);
exec();
}
diff --git a/qt-ui/printdialog.h b/qt-ui/printdialog.h
index e75502997..44bb94669 100644
--- a/qt-ui/printdialog.h
+++ b/qt-ui/printdialog.h
@@ -5,6 +5,7 @@
#include <QPrinter>
#include "../display.h"
+class QProgressBar;
class PrintOptions;
class PrintLayout;
@@ -21,6 +22,7 @@ private:
explicit PrintDialog(QWidget *parent = 0, Qt::WindowFlags f = 0);
PrintOptions *optionsWidget;
PrintLayout *printLayout;
+ QProgressBar *progressBar;
QPrinter printer;
private slots: