mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-08 02:44:16 +02:00
[ui] small refactoring
This commit is contained in:
@@ -18,7 +18,6 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
|||||||
- minor improvements
|
- minor improvements
|
||||||
- download clients parameters
|
- download clients parameters
|
||||||
|
|
||||||
|
|
||||||
### Fixes
|
### Fixes
|
||||||
- regressions (from **0.9.4**)
|
- regressions (from **0.9.4**)
|
||||||
- resetting the main configuration when tray mode is active [#118](https://github.com/vinifmor/bauh/issues/118)
|
- resetting the main configuration when tray mode is active [#118](https://github.com/vinifmor/bauh/issues/118)
|
||||||
@@ -31,6 +30,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
|||||||
- UI
|
- UI
|
||||||
- table overwrite effect when updating its content
|
- table overwrite effect when updating its content
|
||||||
|
|
||||||
|
|
||||||
## [0.9.4] 2020-05-29
|
## [0.9.4] 2020-05-29
|
||||||
|
|
||||||
### Features
|
### Features
|
||||||
|
|||||||
@@ -254,14 +254,12 @@ class AppsTable(QTableWidget):
|
|||||||
self.window.manager.cache_to_disk(pkg=app.model, icon_bytes=icon_data['bytes'], only_icon=True)
|
self.window.manager.cache_to_disk(pkg=app.model, icon_bytes=icon_data['bytes'], only_icon=True)
|
||||||
|
|
||||||
def update_packages(self, pkgs: List[PackageView], update_check_enabled: bool = True):
|
def update_packages(self, pkgs: List[PackageView], update_check_enabled: bool = True):
|
||||||
self.setRowCount(0) # removes the overwrite effect when updates the table
|
self.setRowCount(0) # removes the overwrite effect when updates the table
|
||||||
|
self.setEnabled(True)
|
||||||
|
|
||||||
if pkgs:
|
if pkgs:
|
||||||
self.setRowCount(len(pkgs))
|
self.setRowCount(len(pkgs))
|
||||||
|
|
||||||
self.setEnabled(True)
|
|
||||||
|
|
||||||
if pkgs:
|
|
||||||
for idx, pkg in enumerate(pkgs):
|
for idx, pkg in enumerate(pkgs):
|
||||||
pkg.table_index = idx
|
pkg.table_index = idx
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
import logging
|
import logging
|
||||||
import time
|
import time
|
||||||
import traceback
|
import traceback
|
||||||
from datetime import datetime
|
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from typing import List, Type, Set, Tuple
|
from typing import List, Type, Set, Tuple
|
||||||
|
|
||||||
@@ -777,7 +776,7 @@ class ManageWindow(QWidget):
|
|||||||
|
|
||||||
if old_installed and types:
|
if old_installed and types:
|
||||||
for pkgv in old_installed:
|
for pkgv in old_installed:
|
||||||
if not pkgv.model.__class__ in types:
|
if pkgv.model.__class__ not in types:
|
||||||
commons.update_info(pkgv, pkgs_info)
|
commons.update_info(pkgv, pkgs_info)
|
||||||
commons.apply_filters(pkgv, filters, pkgs_info)
|
commons.apply_filters(pkgv, filters, pkgs_info)
|
||||||
|
|
||||||
@@ -826,7 +825,7 @@ class ManageWindow(QWidget):
|
|||||||
if self.pkgs_installed:
|
if self.pkgs_installed:
|
||||||
self.ref_bt_installed.setVisible(not as_installed and not self.recent_installation)
|
self.ref_bt_installed.setVisible(not as_installed and not self.recent_installation)
|
||||||
|
|
||||||
self._resize(accept_lower_width=self.pkgs_installed)
|
self._resize(accept_lower_width=bool(self.pkgs_installed))
|
||||||
|
|
||||||
if self.first_refresh:
|
if self.first_refresh:
|
||||||
qt_utils.centralize(self)
|
qt_utils.centralize(self)
|
||||||
|
|||||||
Reference in New Issue
Block a user