Bug 3018: ImportGrdb: remove calls to keys() dictionary method where possible

svn: r12572
This commit is contained in:
Gerald Britton
2009-05-26 20:48:09 +00:00
parent 51f65aa02f
commit 5eb7e18dc6
47 changed files with 134 additions and 199 deletions

View File

@ -358,8 +358,8 @@ class DisplayChart(ManagedWindow.ManagedWindow):
else:
the_map[name] = 1
unsort_list = [ (the_map[item], item) for item in the_map.keys() ]
unsort_list.sort(by_value)
unsort_list = sorted([(d, k) for k,d in the_map.iteritems()],by_value)
sort_list = [ item[1] for item in unsort_list ]
## Presently there's no Birth and Death. Instead there's Birth Date and
## Birth Place, as well as Death Date and Death Place.