/// <summary> /// Applies the OutputType property value from combo box control to the vcxproj project. /// <para>The OutputType property is translated to ConfigurationType and Subsystem properties</para> /// </summary> /// <returns>the ConfigurationType associated to OutputType</returns> string ConvertOutputType(ComboBox cbOutputType) { OutputType[] values = (OutputType[])Enum.GetValues(typeof(OutputType)); OutputType outputType = values[cbOutputType.SelectedIndex]; string subsystem = OutputTypeToSubsystem(outputType); MSBuildItemDefinitionGroup group = new MSBuildItemDefinitionGroup(project, helper.Configuration, helper.Platform); group.SetElementMetadata("Link", "SubSystem", subsystem); return OutputTypeToConfigurationType(outputType); }
private static void SetElementMetaData (MSBuildItemDefinitionGroup group,string name,string value) { group.SetElementMetadata(metaElement,name,value); }
/// <summary> /// Applies the OutputType property value from combo box control to the vcxproj project. /// <para>The OutputType property is translated to ConfigurationType and Subsystem properties</para> /// </summary> /// <returns>the ConfigurationType associated to OutputType</returns> string ConvertOutputType() { OutputType[] values = (OutputType[])Enum.GetValues(typeof(OutputType)); OutputType outputType = values[this.outputTypeComboBox.SelectedIndex]; string subsystem = OutputTypeToSubsystem(outputType); MSBuildItemDefinitionGroup group = new MSBuildItemDefinitionGroup(base.Project, base.Project.ActiveConfiguration, base.Project.ActivePlatform); group.SetElementMetadata("Link", "SubSystem", subsystem); return OutputTypeToConfigurationType(outputType); }
private static void SpecifyRuntimeLibrary(MSBuildBasedProject project, string configuration, string runtime) { MSBuildItemDefinitionGroup group = new MSBuildItemDefinitionGroup(project, configuration, null); group.SetElementMetadata("ClCompile", "RuntimeLibrary", runtime); }