mirror of
https://github.com/virt-manager/virt-manager.git
synced 2024-10-27 01:55:20 +03:00
i18n: improve label for floppy
Shortcut all the checks, and directly return the whole string (index included) to show for floppies. Reviewed-by: Cole Robinson <crobinso@redhat.com> Signed-off-by: Pino Toscano <ptoscano@redhat.com>
This commit is contained in:
parent
664197bcc7
commit
7b46ee1947
@ -167,12 +167,12 @@ def _label_for_device(dev):
|
||||
devtype = dev.DEVICE_TYPE
|
||||
|
||||
if devtype == "disk":
|
||||
if dev.device == "floppy":
|
||||
return _("Floppy %(index)d") % {"index": dev.disk_bus_index}
|
||||
|
||||
busstr = vmmAddHardware.disk_pretty_bus(dev.bus) or ""
|
||||
|
||||
if dev.device == "floppy":
|
||||
devstr = _("Floppy")
|
||||
busstr = ""
|
||||
elif dev.device == "cdrom":
|
||||
if dev.device == "cdrom":
|
||||
devstr = _("CDROM")
|
||||
elif dev.device == "disk":
|
||||
devstr = _("Disk")
|
||||
|
Loading…
Reference in New Issue
Block a user