tweak Place details gramplet for alternative names: show language

This commit is contained in:
Paul Franklin 2016-04-05 12:13:40 -07:00
parent 7f4bc4785f
commit b620d6a039

View File

@ -125,7 +125,9 @@ class PlaceDetails(Gramplet):
"""
Display alternative names for the place.
"""
alt_names = [name.get_value() for name in place.get_alternative_names()]
alt_names = ["%s (%s)" % (name.get_value(), name.get_language())
if name.get_language() else name.get_value()
for name in place.get_alternative_names()]
if len(alt_names) > 0:
self.add_row(_('Alternative Names'), '\n'.join(alt_names))