From 96dac68c93417a710e8e619874043a913707993d Mon Sep 17 00:00:00 2001 From: Mark Omwansa Date: Sun, 23 Oct 2022 19:37:54 -0400 Subject: [PATCH] Attribute changes 1. `Accepted` and `Rejected` are now attributes of `QtGui.Dialog` 2. Similarly, Ok, Cancel, Yes, No are now attributes of `QtGui.QMessageBox` --- pyface/ui/qt4/dialog.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pyface/ui/qt4/dialog.py b/pyface/ui/qt4/dialog.py index 10fa5aab6..470f7fabb 100644 --- a/pyface/ui/qt4/dialog.py +++ b/pyface/ui/qt4/dialog.py @@ -26,12 +26,12 @@ # Map PyQt dialog related constants to the pyface equivalents. _RESULT_MAP = { - int(QtGui.QDialog.DialogCode.Accepted): OK, - int(QtGui.QDialog.DialogCode.Rejected): CANCEL, - int(QtGui.QMessageBox.StandardButton.Ok): OK, - int(QtGui.QMessageBox.StandardButton.Cancel): CANCEL, - int(QtGui.QMessageBox.StandardButton.Yes): YES, - int(QtGui.QMessageBox.StandardButton.No): NO, + int(QtGui.QDialog.Accepted): OK, + int(QtGui.QDialog.Rejected): CANCEL, + int(QtGui.QMessageBox.Ok): OK, + int(QtGui.QMessageBox.Cancel): CANCEL, + int(QtGui.QMessageBox.Yes): YES, + int(QtGui.QMessageBox.No): NO, }