Clear SearchBox with ESC key
This commit is contained in:
parent
ad1bcc55b9
commit
2347f75633
@ -71,6 +71,11 @@ class SearchBox(QtGui.QLineEdit):
|
||||
self.selectAll()
|
||||
self.focusing = False
|
||||
|
||||
def keyPressEvent(self, event): # pylint: disable=invalid-name
|
||||
if event.key() == QtCore.Qt.Key_Escape:
|
||||
self.clear()
|
||||
super(SearchBox, self).keyPressEvent(event)
|
||||
|
||||
|
||||
class VmRowInTable:
|
||||
# pylint: disable=too-few-public-methods
|
||||
|
Loading…
Reference in New Issue
Block a user