18 |
18 |
19 def keyPressEvent(self, evt): |
19 def keyPressEvent(self, evt): |
20 """ |
20 """ |
21 Protected method implementing special key handling. |
21 Protected method implementing special key handling. |
22 |
22 |
23 @param evt reference to the event (QKeyEvent) |
23 @param evt reference to the event |
|
24 @type QKeyEvent |
24 """ |
25 """ |
25 if ( |
26 if ( |
26 evt.key() in [Qt.Key.Key_Delete, Qt.Key.Key_Backspace] |
27 evt.key() in [Qt.Key.Key_Delete, Qt.Key.Key_Backspace] |
27 and self.model() is not None |
28 and self.model() is not None |
28 ): |
29 ): |