mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-06 22:54:16 +02:00
[debian] improvement: installation/download sizes order (installation dependencies dialog)
This commit is contained in:
@@ -12,6 +12,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
|||||||
- displaying hard and unnecessary requirements versions and descriptions
|
- displaying hard and unnecessary requirements versions and descriptions
|
||||||
|
|
||||||
- Debian
|
- Debian
|
||||||
|
- install: installation/download sizes order (to follow the upgrade dialog order)
|
||||||
- uninstall: dependencies dialog size
|
- uninstall: dependencies dialog size
|
||||||
|
|
||||||
- General
|
- General
|
||||||
|
|||||||
@@ -36,13 +36,13 @@ class DebianViewBridge:
|
|||||||
else:
|
else:
|
||||||
uncompressed = '?'
|
uncompressed = '?'
|
||||||
|
|
||||||
views.append(InputOption(label=f"{p.name} ({compressed} | {uncompressed})",
|
views.append(InputOption(label=f"{p.name} ({uncompressed} | {compressed})",
|
||||||
value=p.name, read_only=True, icon_path=DEBIAN_ICON_PATH,
|
value=p.name, read_only=True, icon_path=DEBIAN_ICON_PATH,
|
||||||
tooltip=p.description if p.description else '?'))
|
tooltip=p.description if p.description else '?'))
|
||||||
|
|
||||||
dsize = get_human_size_str(download_size) if download_size > 0 else '?'
|
dsize = get_human_size_str(download_size) if download_size > 0 else '?'
|
||||||
isize = get_human_size_str(install_size) if install_size > 0 else '?'
|
isize = get_human_size_str(install_size) if install_size > 0 else '?'
|
||||||
return views, dsize, isize
|
return views, isize, dsize
|
||||||
|
|
||||||
def _map_to_remove(self, pkgs: Optional[Collection[DebianPackage]]) -> Optional[Tuple[List[InputOption], str]]:
|
def _map_to_remove(self, pkgs: Optional[Collection[DebianPackage]]) -> Optional[Tuple[List[InputOption], str]]:
|
||||||
if pkgs:
|
if pkgs:
|
||||||
@@ -88,8 +88,8 @@ class DebianViewBridge:
|
|||||||
if to_install_data:
|
if to_install_data:
|
||||||
to_install_data[0].sort(key=attrgetter('label'))
|
to_install_data[0].sort(key=attrgetter('label'))
|
||||||
lb_deps = self._i18n['debian.transaction.to_install'].format(no=bold(str(len(to_install_data[0]))),
|
lb_deps = self._i18n['debian.transaction.to_install'].format(no=bold(str(len(to_install_data[0]))),
|
||||||
dsize=bold(to_install_data[1]),
|
dsize=bold(to_install_data[2]),
|
||||||
isize=bold(to_install_data[2]))
|
isize=bold(to_install_data[1]))
|
||||||
|
|
||||||
components.append(TextComponent(html=f'<br/>{lb_deps}', min_width=text_width))
|
components.append(TextComponent(html=f'<br/>{lb_deps}', min_width=text_width))
|
||||||
components.append(MultipleSelectComponent(id_='inst', label='', options=to_install_data[0],
|
components.append(MultipleSelectComponent(id_='inst', label='', options=to_install_data[0],
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ debian.task.sync_pkgs.status=Synchronizing packages
|
|||||||
debian.transaction.dependency_of=Dependency of {pkgs}
|
debian.transaction.dependency_of=Dependency of {pkgs}
|
||||||
debian.transaction.get_data=Retrieving the operation's data
|
debian.transaction.get_data=Retrieving the operation's data
|
||||||
debian.transaction.title=Operation details
|
debian.transaction.title=Operation details
|
||||||
debian.transaction.to_install=The following additional packages ({no}) will be installed (Download: {dsize} | Installation: {isize})
|
debian.transaction.to_install=The following additional packages ({no}) will be installed (Installation: {isize} | Download: {dsize})
|
||||||
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
||||||
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
||||||
debian.uninstall.removing=Removing packages
|
debian.uninstall.removing=Removing packages
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ debian.task.sync_pkgs.status=Synchronizing packages
|
|||||||
debian.transaction.dependency_of=Dependency of {pkgs}
|
debian.transaction.dependency_of=Dependency of {pkgs}
|
||||||
debian.transaction.get_data=Retrieving the operation's data
|
debian.transaction.get_data=Retrieving the operation's data
|
||||||
debian.transaction.title=Operation details
|
debian.transaction.title=Operation details
|
||||||
debian.transaction.to_install=The following additional packages ({no}) will be installed (Download: {dsize} | Installation: {isize})
|
debian.transaction.to_install=The following additional packages ({no}) will be installed (Installation: {isize} | Download: {dsize})
|
||||||
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
||||||
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
||||||
debian.uninstall.removing=Removing packages
|
debian.uninstall.removing=Removing packages
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ debian.task.sync_pkgs.status=Synchronizing packages
|
|||||||
debian.transaction.dependency_of=Dependency of {pkgs}
|
debian.transaction.dependency_of=Dependency of {pkgs}
|
||||||
debian.transaction.get_data=Retrieving the operation's data
|
debian.transaction.get_data=Retrieving the operation's data
|
||||||
debian.transaction.title=Operation details
|
debian.transaction.title=Operation details
|
||||||
debian.transaction.to_install=The following additional packages ({no}) will be installed (Download: {dsize} | Installation: {isize})
|
debian.transaction.to_install=The following additional packages ({no}) will be installed (Installation: {isize} | Download: {dsize})
|
||||||
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
||||||
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
||||||
debian.uninstall.removing=Removing packages
|
debian.uninstall.removing=Removing packages
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ debian.task.sync_pkgs.status=Sincronizando paquetes
|
|||||||
debian.transaction.dependency_of=Dependencia de {pkgs}
|
debian.transaction.dependency_of=Dependencia de {pkgs}
|
||||||
debian.transaction.get_data=Recuperando datos de la operación
|
debian.transaction.get_data=Recuperando datos de la operación
|
||||||
debian.transaction.title=Detalles de la operación
|
debian.transaction.title=Detalles de la operación
|
||||||
debian.transaction.to_install=Los siguientes paquetes adicionales ({no}) serán instalados (Descarga: {dsize} | Instalación: {isize})
|
debian.transaction.to_install=Los siguientes paquetes adicionales ({no}) serán instalados (Instalación: {isize} | Descarga: {dsize})
|
||||||
debian.transaction.to_remove=Los siguientes paquetes ({no}) serán eliminados (Espacio liberado: {fspace})
|
debian.transaction.to_remove=Los siguientes paquetes ({no}) serán eliminados (Espacio liberado: {fspace})
|
||||||
debian.uninstall.failed_to_remove=No fue posible eliminar los siguientes {no} paquetes: {pkgs}
|
debian.uninstall.failed_to_remove=No fue posible eliminar los siguientes {no} paquetes: {pkgs}
|
||||||
debian.uninstall.removing=Removendo paquetes
|
debian.uninstall.removing=Removendo paquetes
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ debian.task.sync_pkgs.status=Synchronizing packages
|
|||||||
debian.transaction.dependency_of=Dependency of {pkgs}
|
debian.transaction.dependency_of=Dependency of {pkgs}
|
||||||
debian.transaction.get_data=Retrieving the operation's data
|
debian.transaction.get_data=Retrieving the operation's data
|
||||||
debian.transaction.title=Operation details
|
debian.transaction.title=Operation details
|
||||||
debian.transaction.to_install=The following additional packages ({no}) will be installed (Download: {dsize} | Installation: {isize})
|
debian.transaction.to_install=The following additional packages ({no}) will be installed (Installation: {isize} | Download: {dsize})
|
||||||
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
||||||
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
||||||
debian.uninstall.removing=Removing packages
|
debian.uninstall.removing=Removing packages
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ debian.task.sync_pkgs.status=Synchronizing packages
|
|||||||
debian.transaction.dependency_of=Dependency of {pkgs}
|
debian.transaction.dependency_of=Dependency of {pkgs}
|
||||||
debian.transaction.get_data=Retrieving the operation's data
|
debian.transaction.get_data=Retrieving the operation's data
|
||||||
debian.transaction.title=Operation details
|
debian.transaction.title=Operation details
|
||||||
debian.transaction.to_install=The following additional packages ({no}) will be installed (Download: {dsize} | Installation: {isize})
|
debian.transaction.to_install=The following additional packages ({no}) will be installed (Installation: {isize} | Download: {dsize})
|
||||||
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
||||||
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
||||||
debian.uninstall.removing=Removing packages
|
debian.uninstall.removing=Removing packages
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ debian.task.sync_pkgs.status=Sincronizando pacotes
|
|||||||
debian.transaction.dependency_of=Dependência de {pkgs}
|
debian.transaction.dependency_of=Dependência de {pkgs}
|
||||||
debian.transaction.get_data=Obtendo dados da operação
|
debian.transaction.get_data=Obtendo dados da operação
|
||||||
debian.transaction.title=Detalhes da operação
|
debian.transaction.title=Detalhes da operação
|
||||||
debian.transaction.to_install=Os seguintes pacotes adicionais ({no}) serão instaladas (Download: {dsize} | Instalação: {isize})
|
debian.transaction.to_install=Os seguintes pacotes adicionais ({no}) serão instaladas (Instalação: {isize} | Download: {dsize})
|
||||||
debian.transaction.to_remove=Os seguintes pacotes ({no}) serão removidos (Espaço liberado: {fspace})
|
debian.transaction.to_remove=Os seguintes pacotes ({no}) serão removidos (Espaço liberado: {fspace})
|
||||||
debian.uninstall.failed_to_remove=Não foi possível remover os seguintes {no} pacotes: {pkgs}
|
debian.uninstall.failed_to_remove=Não foi possível remover os seguintes {no} pacotes: {pkgs}
|
||||||
debian.uninstall.removing=Removendo pacotes
|
debian.uninstall.removing=Removendo pacotes
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ debian.task.sync_pkgs.status=Synchronizing packages
|
|||||||
debian.transaction.dependency_of=Dependency of {pkgs}
|
debian.transaction.dependency_of=Dependency of {pkgs}
|
||||||
debian.transaction.get_data=Retrieving the operation's data
|
debian.transaction.get_data=Retrieving the operation's data
|
||||||
debian.transaction.title=Operation details
|
debian.transaction.title=Operation details
|
||||||
debian.transaction.to_install=The following additional packages ({no}) will be installed (Download: {dsize} | Installation: {isize})
|
debian.transaction.to_install=The following additional packages ({no}) will be installed (Installation: {isize} | Download: {dsize})
|
||||||
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
||||||
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
||||||
debian.uninstall.removing=Removing packages
|
debian.uninstall.removing=Removing packages
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ debian.task.sync_pkgs.status=Synchronizing packages
|
|||||||
debian.transaction.dependency_of=Dependency of {pkgs}
|
debian.transaction.dependency_of=Dependency of {pkgs}
|
||||||
debian.transaction.get_data=Retrieving the operation's data
|
debian.transaction.get_data=Retrieving the operation's data
|
||||||
debian.transaction.title=Operation details
|
debian.transaction.title=Operation details
|
||||||
debian.transaction.to_install=The following additional packages ({no}) will be installed (Download: {dsize} | Installation: {isize})
|
debian.transaction.to_install=The following additional packages ({no}) will be installed (Installation: {isize} | Download: {dsize})
|
||||||
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
debian.transaction.to_remove=The following packages ({no}) will be removed (Freed space: {fspace})
|
||||||
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
debian.uninstall.failed_to_remove=It was not possible to remove the following {no} packages: {pkgs}
|
||||||
debian.uninstall.removing=Removing packages
|
debian.uninstall.removing=Removing packages
|
||||||
|
|||||||
Reference in New Issue
Block a user