| 32 | namespace OpenOrienteering { |
| 33 | |
| 34 | PrintProgressDialog::PrintProgressDialog(MapPrinter* map_printer, QWidget* parent, Qt::WindowFlags f) |
| 35 | : QProgressDialog(parent, f) |
| 36 | , map_printer(map_printer) |
| 37 | { |
| 38 | setWindowModality(Qt::ApplicationModal); // Required for OSX, cf. QTBUG-40112 |
| 39 | setRange(0, 100); |
| 40 | setMinimumDuration(0); |
| 41 | setValue(0); |
| 42 | |
| 43 | Q_ASSERT(map_printer); |
| 44 | connect(map_printer, &MapPrinter::printProgress, this, &PrintProgressDialog::setProgress); |
| 45 | connect(this, &PrintProgressDialog::canceled, map_printer, &MapPrinter::cancelPrintMap); |
| 46 | } |
| 47 | |
| 48 | PrintProgressDialog::~PrintProgressDialog() |
| 49 | { |
nothing calls this directly
no outgoing calls
no test coverage detected