public frmFirstRun() { InitializeComponent(); InitializeLocalization(); for (int i = LogLevel.BASIC; i < LogLevel.MAXLOGLEVELS; i++) { logLevels.Add(new LogLevelHelper() { Level = i, Name = LogLevel.GetName(i) }); } string[] locfiles; string[] locs; if (!Loc.GetLocalizations(out locs, out locfiles)) { Log.Write(LogLevel.NORMAL, "frmFirstRun: Cannot get proper language files!"); return; } if (locs.Length != locfiles.Length) { Log.Write(LogLevel.NORMAL, "frmFirstRun: Cannot properly fill the language combobox!"); return; } for (int i = 0; i < locs.Length; i++) { languages.Add(new LanguageHelper() { Abbr = Path.GetFileNameWithoutExtension(locfiles[i]), Name = locs[i] }); } }