dabo Commit
Revision 5474
Date: 2009-10-19 13:11:14 -0700 (Mon, 19 Oct 2009)
Author: Paul
Trac: http://trac.dabodev.com/changeset/5474
Changed:
U trunk/dabo/ui/uiwx/dSpinner.py
Log:
My dSpinners had the curious behavior of saving their value when the user set
it,
and restoring it correctly the next time, but if the user didn't change the
value
explicitly, the next load would result in a None value instead of the old saved
value.
Fixed.
Diff:
Modified: trunk/dabo/ui/uiwx/dSpinner.py
===================================================================
--- trunk/dabo/ui/uiwx/dSpinner.py 2009-10-16 23:09:03 UTC (rev 5473)
+++ trunk/dabo/ui/uiwx/dSpinner.py 2009-10-19 20:11:14 UTC (rev 5474)
@@ -94,6 +94,8 @@
# the name of the control hadn't been set yet.
if self.SaveRestoreValue:
self.restoreValue()
+ # Additionally, if the user never changes the Value,
_value will be None:
+ self._value = self.Value
def _constructed(self):
@@ -410,7 +412,7 @@
self.SpinnerWrap = True
self.FontSize = 10
self.Width = 80
-
+
def onHit(self, evt):
print "HIT!", self.Value, "Hit Type", evt.hitType
_______________________________________________
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]