[PyQt] press ESC while editing mapper
Mario Daniel Carugno
carugnom at gmail.com
Thu Mar 19 19:59:30 GMT 2009
Hi there
I'm doing a dialog with a sql data form and it's OK/Cancel buttons.
The data is managed with model/mapper
I connect the button's cancel.clicked() signal to a method that
reverts changes, quits editing mode,
and do more things like enabling some widgets back. Call that method 'rollback'.
When i'm editing and press the ESC key, the editing finishes and
changes are reverted.
Thats OK, but when i press ESC, i want the same functionality of the
'rollback' method, not just
revert and quit edit mode.
So, while i'm editing, i need to connect the ESC key to the 'rollback'
method. And disconnect it
after done.
Is this possible ? How can i get it ?
Thanks
More information about the PyQt
mailing list