dabo Commit
Revision 7124
Date: 2012-03-28 10:53:08 -0700 (Wed, 28 Mar 2012)
Author: Paul
Trac: http://trac.dabodev.com/changeset/7124
Changed:
U trunk/dabo/lib/datanav/Grid.py
Log:
When FormType eq "PickList" or "Edit", an escape key should hide the form,
which it will do on any other control by default due to the presence of
a CancelButton, but the grid eats the key otherwise in the processEscape()
method. Fixed for Edit forms; PickList forms were already working
correctly.
Diff:
Modified: trunk/dabo/lib/datanav/Grid.py
===================================================================
--- trunk/dabo/lib/datanav/Grid.py 2012-03-22 17:07:48 UTC (rev 7123)
+++ trunk/dabo/lib/datanav/Grid.py 2012-03-28 17:53:08 UTC (rev 7124)
@@ -86,11 +86,12 @@
elif keyCode == dKeys.key_Escape and not hasModifiers:
self.processEsc()
+
def processEsc(self):
- ft = getattr(self.Form, "FormType", None)
- if ft == "PickList":
+ if getattr(self.Form, "FormType", None) in ("PickList", "Edit"):
self.Form.hide()
+
def _onDeleteKey(self, evt):
ft = getattr(self.Form, "FormType", None)
if ft != "PickList":
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message:
http://leafe.com/archives/byMID/[email protected]