Git-Url: http://git.frugalware.org/gitweb/gitweb.cgi?p=frugal-mono-tools.git;a=commitdiff;h=7aec31ee7d21422b9488f8942e3c942b715c3e34
commit 7aec31ee7d21422b9488f8942e3c942b715c3e34 Author: bouleetbil <bouleet...@frogdev.info> Date: Sat Aug 28 12:36:22 2010 +0200 *use Isinstalled instead test if some files exist diff --git a/frugal-mono-tools/MainWindow.cs b/frugal-mono-tools/MainWindow.cs index c2c267d..c76b3df 100644 --- a/frugal-mono-tools/MainWindow.cs +++ b/frugal-mono-tools/MainWindow.cs @@ -202,9 +202,9 @@ public partial class MainWindow : Gtk.Window //network init INT_NM.Active=Outils.ServiceOnStartUp("S99rc.networkmanager"); - EnableDisable(INT_NM,"/usr/sbin/NetworkManager",LIB_NMNotInstalled); + EnableDisable(INT_NM,"networkmanager",LIB_NMNotInstalled); INT_WICD.Active=Outils.ServiceOnStartUp("S99rc.wicd"); - EnableDisable(INT_WICD,"/usr/sbin/wicd",LIB_WICDNotInstalled); + EnableDisable(INT_WICD,"wicd",LIB_WICDNotInstalled); if((!INT_NM.Active) && (!INT_WICD.Active)) { INT_FW.Active=true; @@ -214,11 +214,11 @@ public partial class MainWindow : Gtk.Window INT_FW.Active=false; } //Login Manager init - EnableDisable(INT_XDM,"/usr/bin/xdm",LIB_XDM); - EnableDisable(INT_LXDM,"/usr/sbin/lxdm",LIB_LXDM); - EnableDisable(INT_Slim,"/usr/bin/slim",LIB_SLIM); - EnableDisable(INT_GDM,"/usr/sbin/gdm",LIB_GDM); - EnableDisable(INT_KDM,"/usr/bin/kdm",LIB_KDM); + EnableDisable(INT_XDM,"xdm",LIB_XDM); + EnableDisable(INT_LXDM,"lxdm",LIB_LXDM); + EnableDisable(INT_Slim,"slim",LIB_SLIM); + EnableDisable(INT_GDM,"gdm",LIB_GDM); + EnableDisable(INT_KDM,"kdm",LIB_KDM); try { System.IO.StreamReader textFile = new System.IO.StreamReader(cch_FileLoginManager); @@ -504,10 +504,10 @@ public partial class MainWindow : Gtk.Window /// <param name="text"> /// A <see cref="Label"/> /// </param> - public void EnableDisable(CheckButton INT_Option,string FileToTest, Label text) + public void EnableDisable(CheckButton INT_Option,string packageName, Label text) { //check if file existe for works more quickly - if(!File.Exists(FileToTest)) + if(!Pkg.IsInstalled(packageName)) { INT_Option.Active=false; INT_Option.Inconsistent=true; _______________________________________________ Frugalware-git mailing list Frugalware-git@frugalware.org http://frugalware.org/mailman/listinfo/frugalware-git