aboutsummaryrefslogtreecommitdiffstats
path: root/examples/widgets/dialogs/classwizard/listchooser.py
diff options
context:
space:
mode:
Diffstat (limited to 'examples/widgets/dialogs/classwizard/listchooser.py')
-rw-r--r--examples/widgets/dialogs/classwizard/listchooser.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/examples/widgets/dialogs/classwizard/listchooser.py b/examples/widgets/dialogs/classwizard/listchooser.py
index a51c963c4..6bf47c6d1 100644
--- a/examples/widgets/dialogs/classwizard/listchooser.py
+++ b/examples/widgets/dialogs/classwizard/listchooser.py
@@ -1,14 +1,13 @@
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
-from PySide6.QtCore import (QCoreApplication, QDir, QRegularExpression, Qt,
- Property, Slot)
+from PySide6.QtCore import QRegularExpression, Property, Slot
from PySide6.QtGui import QRegularExpressionValidator
from PySide6.QtWidgets import (QComboBox, QDialog, QDialogButtonBox,
QFormLayout, QGroupBox, QHBoxLayout,
- QInputDialog, QLineEdit, QListWidget,
+ QLineEdit, QListWidget,
QListWidgetItem, QPushButton, QVBoxLayout,
- QWidget)
+ )
DEFAULT_TYPES = ['int', 'str', 'PySide6.QtCore.QPoint', 'PySide6.QtCore.QRect',
@@ -28,7 +27,7 @@ class ValidatingInputDialog(QDialog):
self._lineedit = QLineEdit()
self._lineedit.setClearButtonEnabled(True)
re = QRegularExpression(pattern)
- assert(re.isValid())
+ assert re.isValid()
self._validator = QRegularExpressionValidator(re, self)
self._lineedit.setValidator(self._validator)
self._form_layout.addRow(label, self._lineedit)