I just remembered something from Stackoverflow (http://stackoverflow.com/questions/1568491): a datepicker.Navigate() may also fix this issue. That might be better than a wx.CallAfter. If you have the time, can you try that? So call Navigate() on all datepickers before getting the data out of the datepickers in the ok() method.
Thanks, Frank 2010/1/31 <[email protected]>: > Revision: 2781 > http://taskcoach.svn.sourceforge.net/taskcoach/?rev=2781&view=rev > Author: fraca7 > Date: 2010-01-31 12:42:20 +0000 (Sun, 31 Jan 2010) > > Log Message: > ----------- > Fix #2942425 > > Modified Paths: > -------------- > branches/Release0_78_Branch/changes.in/changes.py > branches/Release0_78_Branch/taskcoachlib/gui/dialog/editor.py > > Modified: branches/Release0_78_Branch/changes.in/changes.py > =================================================================== > --- branches/Release0_78_Branch/changes.in/changes.py 2010-01-31 12:21:20 > UTC (rev 2780) > +++ branches/Release0_78_Branch/changes.in/changes.py 2010-01-31 12:42:20 > UTC (rev 2781) > @@ -26,6 +26,8 @@ > Release('0.78.3', 'January 31, 2010', > summary='''This is a bugfix release.''', > bugsFixed=[ > + Bug('''In some cases, when typing dates in the editor, they would > +be reset to the current day.''', '2942425'), > Bug('''Free up resources (user objects and memory) on Windows when > closing dialogs. The memory leak was caused by popup menu's in dialogs not > being deleted.''', '2938091', '2891350', '2560895', '2444185', '2214043'), > > Modified: branches/Release0_78_Branch/taskcoachlib/gui/dialog/editor.py > =================================================================== > --- branches/Release0_78_Branch/taskcoachlib/gui/dialog/editor.py > 2010-01-31 12:21:20 UTC (rev 2780) > +++ branches/Release0_78_Branch/taskcoachlib/gui/dialog/editor.py > 2010-01-31 12:42:20 UTC (rev 2781) > @@ -435,6 +435,13 @@ > self.suggestReminder() > > def ok(self): > + # Funny things happen with the date pickers without this (to > + # reproduce: create a task, enter the start date by hand, > + # click OK; the date is the current date instead of the one > + # typed in). > + wx.CallAfter(self._ok) > + > + def _ok(self): > recurrenceDict = {0: '', 1: 'daily', 2: 'weekly', 3: 'monthly', 4: > 'yearly'} > kwargs = dict(unit=recurrenceDict[self._recurrenceEntry.Selection]) > if self._maxRecurrenceCheckBox.IsChecked(): > > > This was sent by the SourceForge.net collaborative development platform, the > world's largest Open Source development site. > > ------------------------------------------------------------------------------ > The Planet: dedicated and managed hosting, cloud storage, colocation > Stay online with enterprise data centers and the best network in the business > Choose flexible plans and management services without long-term contracts > Personal 24x7 support from experience hosting pros just a phone call away. > http://p.sf.net/sfu/theplanet-com > _______________________________________________ > Taskcoach-commits mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/taskcoach-commits >
