* src/gramps.glade: Resolve widget naming conflict.

* src/SelectPerson: Resolve widget naming conflict.

* src/Sort.py (by_date): Add function.


svn: r3137
This commit is contained in:
Alex Roitman 2004-05-07 04:11:31 +00:00
parent 350f5d5077
commit a0454e9ac8
2 changed files with 13 additions and 0 deletions

View File

@ -8,6 +8,11 @@
* src/plugins/Makefile.am: Ship CountAncestors.py * src/plugins/Makefile.am: Ship CountAncestors.py
instead of count_anc.py. instead of count_anc.py.
* src/gramps.glade: Resolve widget naming conflict.
* src/SelectPerson: Resolve widget naming conflict.
* src/Sort.py (by_date): Add function.
2004-05-05 Don Allingham <donaldallingham@users.sourceforge.net> 2004-05-05 Don Allingham <donaldallingham@users.sourceforge.net>
* src/plugins/ReadGedcom.py: commit after media object change * src/plugins/ReadGedcom.py: commit after media object change
* src/gramps.glade: file chooser for image selector * src/gramps.glade: file chooser for image selector

View File

@ -120,3 +120,11 @@ class Sort:
if val == 0: if val == 0:
return self.by_last_name(first_id,second_id) return self.by_last_name(first_id,second_id)
return val return val
def by_date(self,a_id,b_id):
"""Sort routine for comparing two events by their dates. """
if not (a_id and b_id):
return 0
a = self.database.find_event_from_id(a_id)
b = self.database.find_event_from_id(b_id)
return Date.compare_dates(a.get_date_object(),b.get_date_object())