Esempio n. 1
0
        private void WriteMIDLParameters(XmlWriter writer, Project project)
        {
            VCppProjectMIDLParameters midlParameters = project.HasParameters("midl")
                                                                   ? project.GetParameters <VCppProjectMIDLParameters>("midl")
                                                                   : new VCppProjectMIDLParameters(Suite);

            midlParameters.FillProjectSpecificMissingInfo(project, targetDir as LocalFileSystemDirectory);

            writer.WriteStartElement("Midl");
            midlParameters.ToVcxprojProperties(writer);
            writer.WriteEndElement();
        }
Esempio n. 2
0
        private XmlElement GetProperties(VCppProjectMIDLParameters p)
        {
            using (var writer = new StringWriter())
                using (var xmlWriter = new XmlTextWriter(writer))
                {
                    xmlWriter.WriteStartElement("Root");
                    p.ToVcxprojProperties(xmlWriter);
                    xmlWriter.WriteEndElement();

                    var doc = new XmlDocument();
                    doc.LoadXml(writer.ToString());
                    return(doc.DocumentElement);
                }
        }