From 3deaa2f6047c7b06540577d2985428019b774d8a Mon Sep 17 00:00:00 2001 From: necoro <> Date: Sat, 31 Mar 2007 20:47:27 +0000 Subject: Some small changes for etcproposals 1.1 --- portato/plugins/etc_proposals.py | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) (limited to 'portato/plugins') diff --git a/portato/plugins/etc_proposals.py b/portato/plugins/etc_proposals.py index e830115..c76fef9 100644 --- a/portato/plugins/etc_proposals.py +++ b/portato/plugins/etc_proposals.py @@ -16,7 +16,7 @@ from portato.backend import system from portato.gui.gtk.dialogs import not_root_dialog from subprocess import Popen -from etcproposals.etcproposals_lib import EtcProposals +from etcproposals.etcproposals_lib import EtcProposals, __version__ class PortatoEtcProposals(EtcProposals): """Subclassed EtcProposals using portato.backend.system during __init__.""" @@ -30,14 +30,21 @@ class PortatoEtcProposals(EtcProposals): def etc_prop (*args, **kwargs): """Entry point for this plugin.""" - l = len(PortatoEtcProposals()) - debug(l,"files to update") - if l > 0: - Popen("etc-proposals") + if float(__version__) < 1.1: + l = len(PortatoEtcProposals()) + debug(l,"files to update") + + if l > 0: + Popen("etc-proposals") + else: + Popen("etc-proposals --frontend gtk --fastexit") def etc_prop_menu (*args, **kwargs): if not am_i_root(): not_root_dialog() else: - Popen("etc-proposals") + if float(__version__) < 1.1: + Popen("etc-proposals") + else: + Popen("etc-proposals --frontend gtk") -- cgit v1.2.3