Exemple #1
0
        static void BuildClassPath(HaXeContext.Context context)
        {
            var platformsFile = Path.Combine("Settings", "Platforms");

            PlatformData.Load(Path.Combine(PathHelper.AppDir, platformsFile));
            PluginBase.CurrentProject = new HaxeProject("haxe")
            {
                CurrentSDK = Environment.GetEnvironmentVariable("HAXEPATH")
            };
            context.BuildClassPath();
            foreach (var it in context.Classpath)
            {
                var path = it.Path;
                foreach (var searchPattern in context.GetExplorerMask())
                {
                    foreach (var fileName in Directory.GetFiles(path, searchPattern, SearchOption.AllDirectories))
                    {
                        it.AddFile(ASFileParser.ParseFile(new FileModel(fileName)
                        {
                            Context = context, haXe = true, Version = 4
                        }));
                    }
                }
                context.RefreshContextCache(path);
            }
        }