dabo Commit
Revision 5463
Date: 2009-10-14 17:34:30 -0700 (Wed, 14 Oct 2009)
Author: Paul
Trac: http://trac.dabodev.com/changeset/5463
Changed:
U trunk/dabo/ui/uiwx/uiApp.py
Log:
Accepted Larry's patch to get zooming working with the number keys.
Ticket #1291
Diff:
Modified: trunk/dabo/ui/uiwx/uiApp.py
===================================================================
--- trunk/dabo/ui/uiwx/uiApp.py 2009-10-15 00:14:37 UTC (rev 5462)
+++ trunk/dabo/ui/uiwx/uiApp.py 2009-10-15 00:34:30 UTC (rev 5463)
@@ -364,13 +364,16 @@
if not self.ActiveForm or alt or not ctl:
evt.Skip()
return
+
try:
char = chr(evt.GetKeyCode())
except (ValueError, OverflowError):
char = None
- plus = char in ("=", "+", wx.WXK_NUMPAD_ADD)
- minus = char in ("-", wx.WXK_NUMPAD_SUBTRACT)
- slash = char in ("/", wx.WXK_NUMPAD_DIVIDE)
+
+ plus = char in ("=", "+") or kcd == wx.WXK_NUMPAD_ADD
+ minus = char == "-" or kcd == wx.WXK_NUMPAD_SUBTRACT
+ slash = char == "/" or kcd == wx.WXK_NUMPAD_DIVIDE
+
if plus:
self.fontZoomIn()
elif minus:
_______________________________________________
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]