eric6/Network/IRC/IrcIdentitiesEditDialog.py

changeset 8222
5994b80b8760
parent 8218
7c09585bd960
child 8259
2bbec88047dd
equal deleted inserted replaced
8221:0572a215bd2f 8222:5994b80b8760
78 78
79 @param obj reference to the object (QObject) 79 @param obj reference to the object (QObject)
80 @param evt reference to the event (QEvent) 80 @param evt reference to the event (QEvent)
81 @return flag indicating that the event should be filtered out (boolean) 81 @return flag indicating that the event should be filtered out (boolean)
82 """ 82 """
83 if obj == self.nicknameEdit and evt.type() == QEvent.Type.KeyPress: 83 if (
84 if evt.key() in [Qt.Key.Key_Enter, Qt.Key.Key_Return]: 84 obj == self.nicknameEdit and
85 self.on_nicknameAddButton_clicked() 85 evt.type() == QEvent.Type.KeyPress and
86 return True 86 evt.key() in [Qt.Key.Key_Enter, Qt.Key.Key_Return]
87 ):
88 self.on_nicknameAddButton_clicked()
89 return True
87 90
88 return super().eventFilter(obj, evt) 91 return super().eventFilter(obj, evt)
89 92
90 def __updateIdentitiesButtons(self): 93 def __updateIdentitiesButtons(self):
91 """ 94 """

eric ide

mercurial