[ui] fix: not able to maximize/minimize the history dialog on some systems

This commit is contained in:
Vinicius Moreira
2020-11-27 19:03:30 -03:00
parent 828196e120
commit e7fe50361a
3 changed files with 4 additions and 7 deletions

View File

@@ -49,6 +49,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- not able to replace an installed package for a new one that replaces it during conflict resolutions (e.g: xapp replaces xapps)
- AUR: not able to find some repository dependencies when their names are not an exact match (e.g: sc-controller [0.4.7-1] relies on "pylibacl". This dependency now is called "python-pylibacl")
- UI
- history dialog: not able to maximize/minimize it on some systems
- wrong tooltips
### i18n

View File

@@ -1,3 +0,0 @@
GREEN = '#91a069'
ORANGE = '#ECB03E'
RED = '#FF614E'

View File

@@ -2,12 +2,11 @@ import operator
from functools import reduce
from PyQt5.QtCore import Qt
from PyQt5.QtGui import QColor, QIcon, QCursor
from PyQt5.QtWidgets import QDialog, QVBoxLayout, QTableWidget, QTableWidgetItem, QHeaderView, QLabel
from PyQt5.QtGui import QIcon, QCursor
from PyQt5.QtWidgets import QDialog, QVBoxLayout, QTableWidget, QHeaderView, QLabel
from bauh.api.abstract.cache import MemoryCache
from bauh.api.abstract.model import PackageHistory
from bauh.view.qt.colors import GREEN, ORANGE
from bauh.view.qt.view_model import PackageView
from bauh.view.util.translation import I18n
@@ -16,7 +15,7 @@ class HistoryDialog(QDialog):
def __init__(self, history: PackageHistory, icon_cache: MemoryCache, i18n: I18n):
super(HistoryDialog, self).__init__()
self.setWindowFlags(self.windowFlags() | Qt.WindowSystemMenuHint | Qt.WindowMinMaxButtonsHint)
self.setWindowFlags(Qt.CustomizeWindowHint | Qt.WindowMinMaxButtonsHint | Qt.WindowCloseButtonHint)
view = PackageView(model=history.pkg, i18n=i18n)