Пример #1
0
        void PopulateModelFromConfig(ProjectConfig config)
        {
            _model.ProjectSettingsPath = config.ProjectSettingsPath;
            _model.UnityPackagesPath   = config.UnityPackagesPath;

            _model.ClearPluginItems();
            foreach (var name in config.PluginsFolder)
            {
                _model.AddPluginItem(name);
            }

            _model.ClearAssetItems();
            foreach (var name in config.AssetsFolder)
            {
                _model.AddAssetItem(name);
            }

            _model.ClearSolutionProjects();
            foreach (var name in config.SolutionProjects)
            {
                _model.AddVsProject(name);
            }

            _model.ClearPrebuiltProjects();
            foreach (var name in config.Prebuilt)
            {
                _model.AddPrebuilt(name);
            }

            _model.ClearSolutionFolders();
            foreach (var pair in config.SolutionFolders)
            {
                _model.AddSolutionFolder(pair.Key, pair.Value);
            }

            _model.ClearSavedPackageFolders();
            foreach (var pair in config.PackageFolders)
            {
                _model.AddSavedPackageFolder(pair);
            }

            _model.ProjectPlatforms = config.ProjectPlatforms;
        }