Werner
2014-06-26 08:54:07 UTC
Hi,
Trying to figure out why in Phoenix all times are marked as invalid.
I don't (didn't) understand the code in maskededit._validateTime:
try:
checkTime = dateHandler.ParseTime(value)
valid = checkTime == len(value)
ParseTime returns True or False (see ParseTime and ParseFormat in
docs.wxwidgets.org/2.9/classwx_date_time.html) , so how could that ever
have worked, as the len(value) can never be equal.
Hhm, just debugged it using wxPython 2.9.5 and there ParseTime returns
"11" for a time string of u"12:00:00 AM".
Was ParseTime changed on purpose to just return True/False or ...?
I was going to just use "IsValid" on dateHandler, but
dateHandler.ParseTime does not actually set the time to the given value.
Any suggestion on how the value could be checked to be valid?
Werner
Trying to figure out why in Phoenix all times are marked as invalid.
I don't (didn't) understand the code in maskededit._validateTime:
try:
checkTime = dateHandler.ParseTime(value)
valid = checkTime == len(value)
ParseTime returns True or False (see ParseTime and ParseFormat in
docs.wxwidgets.org/2.9/classwx_date_time.html) , so how could that ever
have worked, as the len(value) can never be equal.
Hhm, just debugged it using wxPython 2.9.5 and there ParseTime returns
"11" for a time string of u"12:00:00 AM".
Was ParseTime changed on purpose to just return True/False or ...?
I was going to just use "IsValid" on dateHandler, but
dateHandler.ParseTime does not actually set the time to the given value.
Any suggestion on how the value could be checked to be valid?
Werner
--
You received this message because you are subscribed to the Google Groups "wxPython-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to wxPython-dev+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "wxPython-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to wxPython-dev+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.