diff options
author | Cristian Maureira-Fredes <[email protected]> | 2021-04-30 17:49:36 +0200 |
---|---|---|
committer | Cristian Maureira-Fredes <[email protected]> | 2021-05-05 20:44:49 +0200 |
commit | 57e681930f6b4c7c311fc70a66317ef64dee4cb1 (patch) | |
tree | bb74a1c956c54be258ccb79eb2e13fdb82107301 /examples/widgets/richtext | |
parent | 36431b071095b8999347df87621bf23ffcc2ac3d (diff) |
examples: use exec() instead of exec_()
Change-Id: I07dd4339093be8fcc80e63a2ff0448e998356203
Reviewed-by: Friedemann Kleint <[email protected]>
Diffstat (limited to 'examples/widgets/richtext')
-rw-r--r-- | examples/widgets/richtext/orderform/orderform.py | 6 | ||||
-rw-r--r-- | examples/widgets/richtext/syntaxhighlighter/syntaxhighlighter.py | 2 | ||||
-rw-r--r-- | examples/widgets/richtext/textobject/textobject.py | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/examples/widgets/richtext/orderform/orderform.py b/examples/widgets/richtext/orderform/orderform.py index 323be365d..ce0569c47 100644 --- a/examples/widgets/richtext/orderform/orderform.py +++ b/examples/widgets/richtext/orderform/orderform.py @@ -197,7 +197,7 @@ class MainWindow(QMainWindow): def open_dialog(self): dialog = DetailsDialog("Enter Customer Details", self) - if dialog.exec_() == QDialog.Accepted: + if dialog.exec() == QDialog.Accepted: self.create_letter(dialog.sender_name(), dialog.sender_address(), dialog.order_items(), dialog.send_offers()) @@ -211,7 +211,7 @@ class MainWindow(QMainWindow): if editor.textCursor().hasSelection(): dialog.addEnabledOption(QAbstractPrintDialog.PrintSelection) - if dialog.exec_() != QDialog.Accepted: + if dialog.exec() != QDialog.Accepted: return editor.print_(printer) @@ -299,4 +299,4 @@ if __name__ == '__main__': window.resize(640, 480) window.show() window.create_sample() - sys.exit(app.exec_()) + sys.exit(app.exec()) diff --git a/examples/widgets/richtext/syntaxhighlighter/syntaxhighlighter.py b/examples/widgets/richtext/syntaxhighlighter/syntaxhighlighter.py index 97373773e..de86e02f8 100644 --- a/examples/widgets/richtext/syntaxhighlighter/syntaxhighlighter.py +++ b/examples/widgets/richtext/syntaxhighlighter/syntaxhighlighter.py @@ -144,4 +144,4 @@ if __name__ == '__main__': window.resize(640, 512) window.show() window.open_file(os.fspath(Path(__file__).resolve())) - sys.exit(app.exec_()) + sys.exit(app.exec()) diff --git a/examples/widgets/richtext/textobject/textobject.py b/examples/widgets/richtext/textobject/textobject.py index 3877ed4e8..bb0c0b168 100644 --- a/examples/widgets/richtext/textobject/textobject.py +++ b/examples/widgets/richtext/textobject/textobject.py @@ -139,4 +139,4 @@ if __name__ == '__main__': app = QApplication(sys.argv) window = Window() window.show() - sys.exit(app.exec_()) + sys.exit(app.exec()) |