示例#1
0
        private void LoadDefaultStrings()
        {
            _strings        = new LocalisationStrings(_stringPath);
            _defaultStrings = LoadStrings(_stringPath, "en");

            // Get Available language list
            _languageList = new List <LanguageInfo>();
            foreach (CultureInfo language in _strings.GetAvailableLanguages())
            {
                if (language.Name != "en")
                {
                    LanguageInfo langInfo = new LanguageInfo(language);
                    _languageList.Add(langInfo);
                }
            }

            DrawLanguageList(null);

            // Build section trees
            treeSections.Nodes.Clear();

            tvSections.Nodes.Clear();
            foreach (StringSection section in _defaultStrings.Sections)
            {
                treeSections.Nodes.Add(section.SectionName);
                tvSections.Nodes.Add(section.SectionName);
            }
        }
示例#2
0
    private void LoadDefaultStrings()
    {
      _strings = new LocalisationStrings(_stringPath);
      _defaultStrings = LoadStrings(_stringPath, "en");

      // Get Available language list
      _languageList = new List<LanguageInfo>();
      foreach (CultureInfo language in _strings.GetAvailableLanguages())
      {
        if (language.Name != "en")
        {
          LanguageInfo langInfo = new LanguageInfo(language);
          _languageList.Add(langInfo);

        }
      }

      DrawLanguageList(null);

      // Build section trees
      treeSections.Nodes.Clear();
     
      tvSections.Nodes.Clear();
      foreach (StringSection section in _defaultStrings.Sections)
      {
        treeSections.Nodes.Add(section.SectionName);
        tvSections.Nodes.Add(section.SectionName);
      }
    }