Skip to content

Commit 379ddfe

Browse files
committed
switched from QDialog to QAbstractDialog
1 parent d6baa2c commit 379ddfe

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

app/QCpdWindow.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@ void ui_add_printer_aux(gpointer key, gpointer value, gpointer user_data);
1313
QCpdWindow *_window;
1414

1515
QCpdWindow::QCpdWindow(QPrinter *printer, QWidget *parent) :
16-
QDialog(parent),
16+
QAbstractPrintDialog(printer, parent),
1717
masterLayout(new QGridLayout(this)),
1818
tabs(new Tabs(this)),
1919
root(new Root(this)),
2020
preview(new Preview(printer, this)),
21-
controls(new Controls(this))
21+
controls{new Controls(this)}
2222
{
2323
/*
2424
* masterLayout

app/QCpdWindow.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
#define QCPDWINDOW_H
33

44
#include <QAbstractPrintDialog>
5-
#include <QDialog>
65
#include "components.h"
76

87

@@ -26,7 +25,7 @@ typedef struct {
2625
std::string arg2;
2726
} Command;
2827

29-
class QCpdWindow : public QDialog {
28+
class QCpdWindow : public QAbstractPrintDialog {
3029
Q_OBJECT
3130
public:
3231
FrontendObj *f;
@@ -47,6 +46,7 @@ class QCpdWindow : public QDialog {
4746
void addJobHoldUntil(char* startJobOption) {}
4847
void addPagesPerSize(char* pages) {}
4948
void updateAllOptions(const QString &printer) {}
49+
int exec() override { return QDialog::exec();}
5050
gpointer parse_commands(gpointer user_data);
5151
gpointer ui_add_printer(gpointer user_data);
5252

0 commit comments

Comments
 (0)