mirror of
https://github.com/virt-manager/virt-manager.git
synced 2025-02-25 18:55:27 -06:00
inspection: try harder to show a pkg summary
If a package has no summary, try to use the description (if available): - if it is just one line (mostly because the package manager only has a single line as description of a package), then use it fully - if it contains more lines, then take the first only, adding suspension dots to indicate it is longer than that
This commit is contained in:
parent
6e988e994c
commit
ecd66a7df2
@ -2436,6 +2436,13 @@ class vmmDetails(vmmGObjectUI):
|
||||
summary = ""
|
||||
if app["app_summary"]:
|
||||
summary = app["app_summary"]
|
||||
elif app["app_description"]:
|
||||
summary = app["app_description"]
|
||||
pos = summary.find("\n")
|
||||
if pos > -1:
|
||||
summary = _("%(summary)s ...") % {
|
||||
"summary" : summary[0:pos]
|
||||
}
|
||||
|
||||
apps_model.append([name, version, summary])
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user