From 1ba9d8a7ae188d71406bed725408d101f37ad7b2 Mon Sep 17 00:00:00 2001 From: Papoteur Date: Thu, 10 Jan 2019 10:03:51 +0100 Subject: Applications: don't display core application when tainted one is installed --- qml/mageiawelcome.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'qml/mageiawelcome.py') diff --git a/qml/mageiawelcome.py b/qml/mageiawelcome.py index b5e13da..c0be01d 100644 --- a/qml/mageiawelcome.py +++ b/qml/mageiawelcome.py @@ -136,9 +136,15 @@ class Installable(QObject): @pyqtSlot(str, str, result=bool) def installable(self, app,repo): is_app_installed, inst_repo = is_installed(app) - installable = (not is_app_installed) or (repo != inst_repo and inst_repo != "") + installable = (not is_app_installed) or (repo != inst_repo and inst_repo == "") return installable + @pyqtSlot(str, str, result=bool) + def other(self, app, repo): + is_app_installed, inst_repo = is_installed(app) + return (is_app_installed and repo == '' and inst_repo != "") + + def username(): user = pwd.getpwuid(os.getuid())[4] # pw_gecos, i e the real name if user == "": -- cgit v1.2.1