8 public delegate void Callback();
10 private static IConfig cfg
= null;
12 public static void Init(Callback UpdateHandler
)
16 cfg
= new GConfConfig(UpdateHandler
);
20 Console
.WriteLine("Cannot use GConf based config.");
21 Console
.WriteLine(e
.Message
);
22 Console
.WriteLine("Trying to fall back to registry based config.");
24 cfg
= new RegistryConfig(UpdateHandler
);
28 public static void Set(string key
, string val
)
33 public static void Set(string key
, int val
)
37 public static void Set(string key
, bool val
)
42 public static string Get(string key
, string def
)
44 return cfg
.Get(key
, def
);
47 public static int Get(string key
, int def
)
49 return cfg
.Get(key
, def
);
52 public static bool Get(string key
, bool def
)
54 return cfg
.Get(key
, def
);