private void LoadResources()
 {
     Licenses.Add(string.Empty, Strings.Common_ChooseALicense);
     SelectedLicense = string.Empty;
     foreach (var line in _git.GetLicenses())
     {
         Licenses.Add(line, line);
     }
     VisibilityLevels.Add("Private", "Private");
     VisibilityLevels.Add("Internal", "Internal");
     VisibilityLevels.Add("Public", "Public");
     SelectedVisibilityLevels = "Public";
 }
Exemple #2
0
        private void LoadResources()
        {
            GitIgnores.Add(string.Empty, Strings.Common_ChooseAGitIgnore);
            SelectedGitIgnore = string.Empty;
            foreach (var line in _git.GetGitIgnores())
            {
                GitIgnores.Add(line, $"{line} - .gitignore");
            }

            Licenses.Add(string.Empty, Strings.Common_ChooseALicense);
            SelectedLicense = string.Empty;
            foreach (var line in _git.GetLicenses())
            {
                Licenses.Add(line, line);
            }
            string defaultnamespace = _storage.GetUser().Username;

            foreach (var path in _web.GetNamespacesPathList())
            {
                Namespaces.Add(path.id.ToString(), $"{path.name} - {path.full_path}");
                if (path.full_path == defaultnamespace)
                {
                    SelectedNamespaces = path.id.ToString();
                }
            }
            if (Namespaces.Count == 0)
            {
                Namespaces.Add("0", defaultnamespace);
                SelectedNamespaces = "0";
            }

            VisibilityLevels.Add("Private", "Private");
            VisibilityLevels.Add("Internal", "Internal");
            VisibilityLevels.Add("Public", "Public");
            SelectedVisibilityLevels = "Public";
        }