Addon Manager: Black and lint

This commit is contained in:
Chris Hennes
2023-03-31 13:46:13 -05:00
parent 43ee59c82f
commit 8b31d7deb0
19 changed files with 146 additions and 115 deletions

View File

@@ -664,7 +664,9 @@ class MissingDependencies:
translate(
"AddonsInstaller",
"Got an error when trying to import {}",
).format(py_dep) + ":\n" + str(e)
).format(py_dep)
+ ":\n"
+ str(e)
)
self.python_optional = []
@@ -678,7 +680,9 @@ class MissingDependencies:
translate(
"AddonsInstaller",
"Got an error when trying to import {}",
).format(py_dep) + ":\n" + str(e)
).format(py_dep)
+ ":\n"
+ str(e)
)
self.wbs.sort()

View File

@@ -36,9 +36,7 @@ class TestAddon(unittest.TestCase):
MODULE = "test_addon" # file name without extension
def setUp(self):
self.test_dir = os.path.join(
os.path.dirname(__file__), "..", "data"
)
self.test_dir = os.path.join(os.path.dirname(__file__), "..", "data")
def test_display_name(self):
@@ -178,7 +176,8 @@ class TestAddon(unittest.TestCase):
self.assertEqual(addon.repo_type, Addon.Kind.MACRO)
self.assertEqual(addon.name, "DoNothing")
self.assertEqual(
addon.macro.comment, "Do absolutely nothing. For Addon Manager integration tests."
addon.macro.comment,
"Do absolutely nothing. For Addon Manager integration tests.",
)
self.assertEqual(addon.url, "https://github.com/FreeCAD/FreeCAD")
self.assertEqual(addon.macro.version, "1.0")

View File

@@ -116,7 +116,9 @@ class TestAddonInstaller(unittest.TestCase):
os.path.join(self.test_data_dir, "good_package.xml"),
os.path.join(addon_dir, "package.xml"),
)
good_metadata = MetadataReader.from_file(os.path.join(addon_dir, "package.xml"))
good_metadata = MetadataReader.from_file(
os.path.join(addon_dir, "package.xml")
)
installer._update_metadata()
self.assertEqual(self.real_addon.installed_version, good_metadata.version)

View File

@@ -204,9 +204,13 @@ class TestUrlType(unittest.TestCase):
class TestMetadataAuxiliaryFunctions(unittest.TestCase):
def test_get_first_supported_freecad_version_simple(self):
from addonmanager_metadata import Metadata, Version, get_first_supported_freecad_version
from addonmanager_metadata import (
Metadata,
Version,
get_first_supported_freecad_version,
)
expected_result = Version(from_string="0.20.2beta")
metadata = self.given_metadata_with_freecadmin_set(expected_result)
first_version = get_first_supported_freecad_version(metadata)
@@ -215,12 +219,18 @@ class TestMetadataAuxiliaryFunctions(unittest.TestCase):
@staticmethod
def given_metadata_with_freecadmin_set(min_version):
from addonmanager_metadata import Metadata
metadata = Metadata()
metadata.freecadmin = min_version
return metadata
def test_get_first_supported_freecad_version_with_content(self):
from addonmanager_metadata import Metadata, Version, get_first_supported_freecad_version
from addonmanager_metadata import (
Metadata,
Version,
get_first_supported_freecad_version,
)
expected_result = Version(from_string="0.20.2beta")
metadata = self.given_metadata_with_freecadmin_in_content(expected_result)
first_version = get_first_supported_freecad_version(metadata)
@@ -229,17 +239,24 @@ class TestMetadataAuxiliaryFunctions(unittest.TestCase):
@staticmethod
def given_metadata_with_freecadmin_in_content(min_version):
from addonmanager_metadata import Metadata, Version
v_list = min_version.version_as_list
metadata = Metadata()
wb1 = Metadata()
wb1.freecadmin = Version(from_list=[v_list[0]+1,v_list[1],v_list[2],v_list[3]])
wb1.freecadmin = Version(
from_list=[v_list[0] + 1, v_list[1], v_list[2], v_list[3]]
)
wb2 = Metadata()
wb2.freecadmin = Version(from_list=[v_list[0],v_list[1]+1,v_list[2],v_list[3]])
wb2.freecadmin = Version(
from_list=[v_list[0], v_list[1] + 1, v_list[2], v_list[3]]
)
wb3 = Metadata()
wb3.freecadmin = Version(from_list=[v_list[0],v_list[1],v_list[2]+1,v_list[3]])
wb3.freecadmin = Version(
from_list=[v_list[0], v_list[1], v_list[2] + 1, v_list[3]]
)
m1 = Metadata()
m1.freecadmin = min_version
metadata.content = {"workbench":[wb1,wb2,wb3],"macro":[m1]}
metadata.content = {"workbench": [wb1, wb2, wb3], "macro": [m1]}
return metadata

View File

@@ -67,9 +67,9 @@ class DialogInteractor(QtCore.QObject):
# doesn't set the title of a modal dialog:
os = QtCore.QSysInfo.productType() # Qt5 gives "osx", Qt6 gives "macos"
if os in ["osx", "macos"] or (
hasattr(widget, "windowTitle")
and callable(widget.windowTitle)
and widget.windowTitle() == self.dialog_to_watch_for
hasattr(widget, "windowTitle")
and callable(widget.windowTitle)
and widget.windowTitle() == self.dialog_to_watch_for
):
return True
return False

View File

@@ -45,7 +45,6 @@ class TestInstallerGui(unittest.TestCase):
self.installer_gui = AddonInstallerGUI(self.addon_to_install)
self.finalized_thread = False
def tearDown(self):
pass

View File

@@ -108,7 +108,9 @@ class TestUninstallerGUI(unittest.TestCase):
translate("AddonsInstaller", "Removing Addon"),
QtWidgets.QDialogButtonBox.Cancel,
)
QtCore.QTimer.singleShot(1000, worker.stop) # If the test fails, this kills the "worker"
QtCore.QTimer.singleShot(
1000, worker.stop
) # If the test fails, this kills the "worker"
self.uninstaller_gui._confirm_uninstallation = lambda: True
self.uninstaller_gui._run_uninstaller = worker.work
self.uninstaller_gui._finalize = lambda: None

View File

@@ -122,6 +122,7 @@ class TestUpdateAllGui(unittest.TestCase):
self.counter = 0
self.LIMIT = 100
self.limit_reached = False
def run(self):
while self.counter < self.LIMIT:
if QtCore.QThread.currentThread().isInterruptionRequested():
@@ -129,6 +130,7 @@ class TestUpdateAllGui(unittest.TestCase):
self.counter += 1
sleep(0.01)
self.limit_reached = True
worker = Worker()
self.factory.work_function = worker.run
self.test_object.run()

View File

@@ -45,7 +45,9 @@ class TestWorkersStartup(unittest.TestCase):
MODULE = "test_workers_startup" # file name without extension
@unittest.skipUnless(run_slow_tests, "This integration test is slow and uses the network")
@unittest.skipUnless(
run_slow_tests, "This integration test is slow and uses the network"
)
def setUp(self):
"""Set up the test"""
self.test_dir = os.path.join(

View File

@@ -58,7 +58,7 @@ from AddonManagerTest.app.test_metadata import (
TestMetadataReaderIntegration as AddonManagerTestMetadataReaderIntegration,
TestUrlType as AddonManagerTestUrlType,
TestVersion as AddonManagerTestVersion,
TestMetadataAuxiliaryFunctions as AddonManagerTestMetadataAuxiliaryFunctions
TestMetadataAuxiliaryFunctions as AddonManagerTestMetadataAuxiliaryFunctions,
)
@@ -90,7 +90,7 @@ loaded_gui_tests = [
AddonManagerTestUrlType,
AddonManagerTestVersion,
AddonManagerTestMetadataAuxiliaryFunctions,
TestListTerminator # Needed to prevent the last test from running twice
TestListTerminator, # Needed to prevent the last test from running twice
]
for test in loaded_gui_tests:
fci.Console.PrintLog(f"Loaded tests from {test.__name__}\n")

View File

@@ -59,7 +59,7 @@ loaded_gui_tests = [
AddonManagerTestMacroInstallerGui,
AddonManagerTestUpdateAllGui,
AddonManagerTestUninstallerGUI,
TestListTerminator # Needed to prevent the last test from running twice
TestListTerminator, # Needed to prevent the last test from running twice
]
for test in loaded_gui_tests:
fci.Console.PrintLog(f"Loaded tests from {test.__name__}\n")

View File

@@ -107,7 +107,7 @@ class MetadataValidators:
return errors
def validate_top_level(self, addon:Addon) -> List[str]:
def validate_top_level(self, addon: Addon) -> List[str]:
"""Check for the presence of the required top-level elements"""
errors = []
if not addon.metadata.name or len(addon.metadata.name) == 0:
@@ -185,7 +185,7 @@ class MetadataValidators:
return errors
@staticmethod
def validate_workbench_metadata(workbench:Metadata) -> List[str]:
def validate_workbench_metadata(workbench: Metadata) -> List[str]:
"""Validate the required element(s) for a workbench"""
errors = []
if not workbench.classname or len(workbench.classname) == 0:
@@ -193,7 +193,7 @@ class MetadataValidators:
return errors
@staticmethod
def validate_preference_pack_metadata(pack:Metadata) -> List[str]:
def validate_preference_pack_metadata(pack: Metadata) -> List[str]:
"""Validate the required element(s) for a preference pack"""
errors = []
if not pack.name or len(pack.name) == 0:

View File

@@ -80,7 +80,9 @@ class AddonInstallerGUI(QtCore.QObject):
self.worker_thread.quit()
self.worker_thread.wait(500)
if self.worker_thread.isRunning():
FreeCAD.Console.PrintError("INTERNAL ERROR: Thread did not quit() cleanly, using terminate()\n")
FreeCAD.Console.PrintError(
"INTERNAL ERROR: Thread did not quit() cleanly, using terminate()\n"
)
self.worker_thread.terminate()
def run(self):
@@ -319,7 +321,7 @@ class AddonInstallerGUI(QtCore.QObject):
translate("AddonsInstaller", "Installing dependencies"),
translate("AddonsInstaller", "Installing dependencies") + "...",
QtWidgets.QMessageBox.Cancel,
parent=utils.get_main_am_window()
parent=utils.get_main_am_window(),
)
self.dependency_installation_dialog.rejected.connect(
self._cancel_dependency_installation
@@ -332,7 +334,9 @@ class AddonInstallerGUI(QtCore.QObject):
self.dependency_worker_thread.quit()
self.dependency_worker_thread.wait(500)
if self.dependency_worker_thread.isRunning():
FreeCAD.Console.PrintError("INTERNAL ERROR: Thread did not quit() cleanly, using terminate()\n")
FreeCAD.Console.PrintError(
"INTERNAL ERROR: Thread did not quit() cleanly, using terminate()\n"
)
self.dependency_worker_thread.terminate()
def _report_no_python_exe(self) -> None:
@@ -444,7 +448,7 @@ class AddonInstallerGUI(QtCore.QObject):
self.addon_to_install.display_name
),
QtWidgets.QMessageBox.Cancel,
parent=utils.get_main_am_window()
parent=utils.get_main_am_window(),
)
self.installing_dialog.rejected.connect(self._cancel_addon_installation)
self.installer.finished.connect(self.installing_dialog.hide)
@@ -459,7 +463,7 @@ class AddonInstallerGUI(QtCore.QObject):
self.addon_to_install.display_name
),
QtWidgets.QMessageBox.NoButton,
parent=utils.get_main_am_window()
parent=utils.get_main_am_window(),
)
dlg.show()
if self.worker_thread.isRunning():
@@ -536,7 +540,9 @@ class MacroInstallerGUI(QtCore.QObject):
self.worker_thread.quit()
self.worker_thread.wait(500)
if self.worker_thread.isRunning():
FreeCAD.Console.PrintError("INTERNAL ERROR: Thread did not quit() cleanly, using terminate()\n")
FreeCAD.Console.PrintError(
"INTERNAL ERROR: Thread did not quit() cleanly, using terminate()\n"
)
self.worker_thread.terminate()
def run(self):

View File

@@ -1,43 +1,45 @@
{
"AddonFlagsURL": "https://raw.githubusercontent.com/FreeCAD/FreeCAD-addons/master/addonflags.json",
"AddonsRemoteCacheURL": "https://addons.freecad.org/metadata.zip",
"AddonsUpdateStatsURL": "https://addons.freecad.org/addon_update_stats.json",
"AutoCheck": false,
"BlockedMacros": "BOLTS,WorkFeatures,how to install,documentation,PartsLibrary,FCGear",
"CustomRepoHash": "",
"CustomRepositories": "",
"CustomToolbarName": "Auto-Created Macro Toolbar",
"DaysBetweenUpdates": -1,
"DownloadMacros": false,
"GitExecutable": "Not set",
"HideNewerFreeCADRequired": true,
"HideObsolete": true,
"HidePy2": true,
"KnownPythonVersions": "[]",
"LastCacheUpdate": "never",
"MacroCacheUpdateFrequency": 7,
"MacroGitURL": "https://github.com/FreeCAD/FreeCAD-Macros",
"MacroUpdateStatsURL": "https://addons.freecad.org/macro_update_stats.json",
"MacroWikiURL": "https://wiki.freecad.org/Macros_recipes",
"NoProxyCheck": "",
"PackageTypeSelection": 1,
"PrimaryAddonsSubmoduleURL": "https://raw.githubusercontent.com/FreeCAD/FreeCAD-addons/master/.gitmodules",
"ProxyUrl": "",
"PythonExecutableForPip": "Not set",
"RemoteIconCacheURL": "https://addons.freecad.org/icon_cache.zip",
"SelectedAddon": "",
"ShowBranchSwitcher": false,
"StatusSelection": 0,
"SystemProxyCheck": "",
"UpdateFrequencyComboEntry": 0,
"UserProxyCheck": "",
"ViewStyle": 1,
"WindowHeight": 600,
"WindowWidth": 800,
"alwaysAskForToolbar": true,
"devModeLastSelectedLicense": "LGPLv2.1",
"developerMode": false,
"disableGit": false,
"dontShowAddMacroButtonDialog": false,
"readWarning2022": false
}
"AddonFlagsURL":
"https://raw.githubusercontent.com/FreeCAD/FreeCAD-addons/master/addonflags.json",
"AddonsRemoteCacheURL": "https://addons.freecad.org/metadata.zip",
"AddonsUpdateStatsURL": "https://addons.freecad.org/addon_update_stats.json",
"AutoCheck": false,
"BlockedMacros": "BOLTS,WorkFeatures,how to install,documentation,PartsLibrary,FCGear",
"CustomRepoHash": "",
"CustomRepositories": "",
"CustomToolbarName": "Auto-Created Macro Toolbar",
"DaysBetweenUpdates": -1,
"DownloadMacros": false,
"GitExecutable": "Not set",
"HideNewerFreeCADRequired": true,
"HideObsolete": true,
"HidePy2": true,
"KnownPythonVersions": "[]",
"LastCacheUpdate": "never",
"MacroCacheUpdateFrequency": 7,
"MacroGitURL": "https://github.com/FreeCAD/FreeCAD-Macros",
"MacroUpdateStatsURL": "https://addons.freecad.org/macro_update_stats.json",
"MacroWikiURL": "https://wiki.freecad.org/Macros_recipes",
"NoProxyCheck": "",
"PackageTypeSelection": 1,
"PrimaryAddonsSubmoduleURL":
"https://raw.githubusercontent.com/FreeCAD/FreeCAD-addons/master/.gitmodules",
"ProxyUrl": "",
"PythonExecutableForPip": "Not set",
"RemoteIconCacheURL": "https://addons.freecad.org/icon_cache.zip",
"SelectedAddon": "",
"ShowBranchSwitcher": false,
"StatusSelection": 0,
"SystemProxyCheck": "",
"UpdateFrequencyComboEntry": 0,
"UserProxyCheck": "",
"ViewStyle": 1,
"WindowHeight": 600,
"WindowWidth": 800,
"alwaysAskForToolbar": true,
"devModeLastSelectedLicense": "LGPLv2.1",
"developerMode": false,
"disableGit": false,
"dontShowAddMacroButtonDialog": false,
"readWarning2022": false
}

View File

@@ -98,7 +98,7 @@ class AddonUninstallerGUI(QtCore.QObject):
)
+ "...",
QtWidgets.QMessageBox.Cancel,
parent = utils.get_main_am_window()
parent=utils.get_main_am_window(),
)
self.progress_dialog.rejected.connect(self._cancel_removal)
self.progress_dialog.show()

View File

@@ -347,6 +347,7 @@ def is_float(element: Any) -> bool:
except ValueError:
return False
def get_python_exe() -> str:
"""Find Python. In preference order
A) The value of the PythonExecutableForPip user preference
@@ -448,11 +449,8 @@ def run_interruptable_subprocess(args) -> subprocess.CompletedProcess:
p.kill()
raise ProcessInterrupted()
if return_code is None or return_code != 0:
raise subprocess.CalledProcessError (
return_code if return_code is not None else -1,
args,
stdout,
stderr
raise subprocess.CalledProcessError(
return_code if return_code is not None else -1, args, stdout, stderr
)
return subprocess.CompletedProcess(args, return_code, stdout, stderr)

View File

@@ -16,7 +16,7 @@ from PySide.QtWidgets import *
class Ui_CompactView(object):
def setupUi(self, CompactView):
if not CompactView.objectName():
CompactView.setObjectName(u"CompactView")
CompactView.setObjectName("CompactView")
CompactView.resize(489, 16)
sizePolicy = QSizePolicy(QSizePolicy.Expanding, QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
@@ -24,11 +24,11 @@ class Ui_CompactView(object):
sizePolicy.setHeightForWidth(CompactView.sizePolicy().hasHeightForWidth())
CompactView.setSizePolicy(sizePolicy)
self.horizontalLayout_2 = QHBoxLayout(CompactView)
self.horizontalLayout_2.setObjectName(u"horizontalLayout_2")
self.horizontalLayout_2.setObjectName("horizontalLayout_2")
self.horizontalLayout_2.setSizeConstraint(QLayout.SetNoConstraint)
self.horizontalLayout_2.setContentsMargins(3, 0, 9, 0)
self.labelIcon = QLabel(CompactView)
self.labelIcon.setObjectName(u"labelIcon")
self.labelIcon.setObjectName("labelIcon")
sizePolicy1 = QSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed)
sizePolicy1.setHorizontalStretch(0)
sizePolicy1.setVerticalStretch(0)
@@ -40,17 +40,17 @@ class Ui_CompactView(object):
self.horizontalLayout_2.addWidget(self.labelIcon)
self.labelPackageName = QLabel(CompactView)
self.labelPackageName.setObjectName(u"labelPackageName")
self.labelPackageName.setObjectName("labelPackageName")
self.horizontalLayout_2.addWidget(self.labelPackageName)
self.labelVersion = QLabel(CompactView)
self.labelVersion.setObjectName(u"labelVersion")
self.labelVersion.setObjectName("labelVersion")
self.horizontalLayout_2.addWidget(self.labelVersion)
self.labelDescription = QLabel(CompactView)
self.labelDescription.setObjectName(u"labelDescription")
self.labelDescription.setObjectName("labelDescription")
sizePolicy2 = QSizePolicy(QSizePolicy.MinimumExpanding, QSizePolicy.Preferred)
sizePolicy2.setHorizontalStretch(0)
sizePolicy2.setVerticalStretch(0)
@@ -65,7 +65,7 @@ class Ui_CompactView(object):
self.horizontalLayout_2.addWidget(self.labelDescription)
self.labelStatus = QLabel(CompactView)
self.labelStatus.setObjectName(u"labelStatus")
self.labelStatus.setObjectName("labelStatus")
self.horizontalLayout_2.addWidget(self.labelStatus)
@@ -77,20 +77,20 @@ class Ui_CompactView(object):
def retranslateUi(self, CompactView):
CompactView.setWindowTitle(
QCoreApplication.translate("CompactView", u"Form", None)
QCoreApplication.translate("CompactView", "Form", None)
)
self.labelIcon.setText(QCoreApplication.translate("CompactView", u"Icon", None))
self.labelIcon.setText(QCoreApplication.translate("CompactView", "Icon", None))
self.labelPackageName.setText(
QCoreApplication.translate("CompactView", u"<b>Package Name</b>", None)
QCoreApplication.translate("CompactView", "<b>Package Name</b>", None)
)
self.labelVersion.setText(
QCoreApplication.translate("CompactView", u"Version", None)
QCoreApplication.translate("CompactView", "Version", None)
)
self.labelDescription.setText(
QCoreApplication.translate("CompactView", u"Description", None)
QCoreApplication.translate("CompactView", "Description", None)
)
self.labelStatus.setText(
QCoreApplication.translate("CompactView", u"UpdateAvailable", None)
QCoreApplication.translate("CompactView", "UpdateAvailable", None)
)
# retranslateUi

View File

@@ -16,7 +16,7 @@ from PySide.QtWidgets import *
class Ui_ExpandedView(object):
def setupUi(self, ExpandedView):
if not ExpandedView.objectName():
ExpandedView.setObjectName(u"ExpandedView")
ExpandedView.setObjectName("ExpandedView")
ExpandedView.resize(807, 141)
sizePolicy = QSizePolicy(QSizePolicy.MinimumExpanding, QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
@@ -25,11 +25,11 @@ class Ui_ExpandedView(object):
ExpandedView.setSizePolicy(sizePolicy)
self.horizontalLayout_2 = QHBoxLayout(ExpandedView)
self.horizontalLayout_2.setSpacing(2)
self.horizontalLayout_2.setObjectName(u"horizontalLayout_2")
self.horizontalLayout_2.setObjectName("horizontalLayout_2")
self.horizontalLayout_2.setSizeConstraint(QLayout.SetNoConstraint)
self.horizontalLayout_2.setContentsMargins(2, 0, 2, 0)
self.labelIcon = QLabel(ExpandedView)
self.labelIcon.setObjectName(u"labelIcon")
self.labelIcon.setObjectName("labelIcon")
sizePolicy1 = QSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed)
sizePolicy1.setHorizontalStretch(0)
sizePolicy1.setVerticalStretch(0)
@@ -49,17 +49,17 @@ class Ui_ExpandedView(object):
self.verticalLayout = QVBoxLayout()
self.verticalLayout.setSpacing(3)
self.verticalLayout.setObjectName(u"verticalLayout")
self.verticalLayout.setObjectName("verticalLayout")
self.horizontalLayout = QHBoxLayout()
self.horizontalLayout.setSpacing(10)
self.horizontalLayout.setObjectName(u"horizontalLayout")
self.horizontalLayout.setObjectName("horizontalLayout")
self.labelPackageName = QLabel(ExpandedView)
self.labelPackageName.setObjectName(u"labelPackageName")
self.labelPackageName.setObjectName("labelPackageName")
self.horizontalLayout.addWidget(self.labelPackageName)
self.labelVersion = QLabel(ExpandedView)
self.labelVersion.setObjectName(u"labelVersion")
self.labelVersion.setObjectName("labelVersion")
self.labelVersion.setTextFormat(Qt.RichText)
sizePolicy2 = QSizePolicy(QSizePolicy.Preferred, QSizePolicy.Preferred)
sizePolicy2.setHorizontalStretch(0)
@@ -72,7 +72,7 @@ class Ui_ExpandedView(object):
self.horizontalLayout.addWidget(self.labelVersion)
self.labelTags = QLabel(ExpandedView)
self.labelTags.setObjectName(u"labelTags")
self.labelTags.setObjectName("labelTags")
self.horizontalLayout.addWidget(self.labelTags)
@@ -85,7 +85,7 @@ class Ui_ExpandedView(object):
self.verticalLayout.addLayout(self.horizontalLayout)
self.labelDescription = QLabel(ExpandedView)
self.labelDescription.setObjectName(u"labelDescription")
self.labelDescription.setObjectName("labelDescription")
sizePolicy.setHeightForWidth(
self.labelDescription.sizePolicy().hasHeightForWidth()
)
@@ -97,7 +97,7 @@ class Ui_ExpandedView(object):
self.verticalLayout.addWidget(self.labelDescription)
self.labelMaintainer = QLabel(ExpandedView)
self.labelMaintainer.setObjectName(u"labelMaintainer")
self.labelMaintainer.setObjectName("labelMaintainer")
sizePolicy2.setHeightForWidth(
self.labelMaintainer.sizePolicy().hasHeightForWidth()
)
@@ -110,7 +110,7 @@ class Ui_ExpandedView(object):
self.horizontalLayout_2.addLayout(self.verticalLayout)
self.labelStatus = QLabel(ExpandedView)
self.labelStatus.setObjectName(u"labelStatus")
self.labelStatus.setObjectName("labelStatus")
self.labelStatus.setTextFormat(Qt.RichText)
self.labelStatus.setAlignment(
Qt.AlignRight | Qt.AlignTrailing | Qt.AlignVCenter
@@ -126,28 +126,26 @@ class Ui_ExpandedView(object):
def retranslateUi(self, ExpandedView):
ExpandedView.setWindowTitle(
QCoreApplication.translate("ExpandedView", u"Form", None)
)
self.labelIcon.setText(
QCoreApplication.translate("ExpandedView", u"Icon", None)
QCoreApplication.translate("ExpandedView", "Form", None)
)
self.labelIcon.setText(QCoreApplication.translate("ExpandedView", "Icon", None))
self.labelPackageName.setText(
QCoreApplication.translate("ExpandedView", u"<h1>Package Name</h1>", None)
QCoreApplication.translate("ExpandedView", "<h1>Package Name</h1>", None)
)
self.labelVersion.setText(
QCoreApplication.translate("ExpandedView", u"Version", None)
QCoreApplication.translate("ExpandedView", "Version", None)
)
self.labelTags.setText(
QCoreApplication.translate("ExpandedView", u"(tags)", None)
QCoreApplication.translate("ExpandedView", "(tags)", None)
)
self.labelDescription.setText(
QCoreApplication.translate("ExpandedView", u"Description", None)
QCoreApplication.translate("ExpandedView", "Description", None)
)
self.labelMaintainer.setText(
QCoreApplication.translate("ExpandedView", u"Maintainer", None)
QCoreApplication.translate("ExpandedView", "Maintainer", None)
)
self.labelStatus.setText(
QCoreApplication.translate("ExpandedView", u"UpdateAvailable", None)
QCoreApplication.translate("ExpandedView", "UpdateAvailable", None)
)
# retranslateUi

View File

@@ -93,4 +93,4 @@ SOFTWARE.
<body>
<div class="loading">Loading...</div>
</body>
</html>
</html>