Git-Url: http://git.frugalware.org/gitweb/gitweb.cgi?p=frugal-tweak.git;a=commitdiff;h=5e2eec0f5f339df11351a89389b7896d6f1e2d46
commit 5e2eec0f5f339df11351a89389b7896d6f1e2d46 Author: bouleetbil <bouleet...@frogdev.info> Date: Fri Sep 17 18:27:13 2010 +0200 *find all system keymaps diff --git a/frugal-mono-tools/ConfSystem.cs b/frugal-mono-tools/ConfSystem.cs index 6cb1b27..4b91781 100644 --- a/frugal-mono-tools/ConfSystem.cs +++ b/frugal-mono-tools/ConfSystem.cs @@ -34,6 +34,7 @@ namespace frugalmonotools private string _distribution; //can't change it private string _keymap; public List<string> LocaleSystem = new List<string>(); + public List<string> KeymapSystem = new List<string>(); public string GetHostname() { return _hostname; @@ -97,6 +98,22 @@ namespace frugalmonotools this.SetHostname(Outils.ReadFile(cch_hostname).ToString().Replace("\n","")); this._distribution=Outils.ReadFile(cch_release).ToString().Replace("\n",""); _findLocaleSystem(); + _findKeymapSystem(); + } + private void _findKeymapSystem() + { + string ext=".map.gz"; + string dirKeymap="/usr/share/keymaps/"; + string[] files= Directory.GetFiles(dirKeymap,"*"+ext,SearchOption.AllDirectories); + + foreach (string file in files) + { + string strKeymap = file; + strKeymap=System.IO.Path.GetFileName(strKeymap); + strKeymap=strKeymap.Replace(ext,""); + KeymapSystem.Add(strKeymap); + + } } private void _findLocaleSystem() { _______________________________________________ Frugalware-git mailing list Frugalware-git@frugalware.org http://frugalware.org/mailman/listinfo/frugalware-git