show event won't be skipped

This commit is contained in:
iLLiCiTiT 2021-05-03 13:25:24 +02:00
parent 3669436aa1
commit 62a7bdfca8

View file

@ -30,9 +30,6 @@ class PasswordDialog(QtWidgets.QDialog):
password_input = QtWidgets.QLineEdit(password_widget)
password_input.setEchoMode(QtWidgets.QLineEdit.Password)
current_dir = os.path.join(
os.path.dirname(os.path.abspath(__file__))
)
show_password_icon_path = get_resource("images", "eye.png")
show_password_icon = QtGui.QIcon(show_password_icon_path)
show_password_btn = QtWidgets.QPushButton(password_widget)
@ -88,11 +85,6 @@ class PasswordDialog(QtWidgets.QDialog):
return event.accept()
super(PasswordDialog, self).keyPressEvent(event)
def showEvent(self, event):
super(PasswordDialog, self).showEvent(event)
if self.result():
self.close()
def closeEvent(self, event):
self.finished.emit(self.result())
super(PasswordDialog, self).closeEvent(event)