Skip to content

Commit

Permalink
Update SampleCsEto for .NET 7 support
Browse files Browse the repository at this point in the history
  • Loading branch information
cwensley committed Aug 28, 2024
1 parent b70ec3f commit 994269a
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 123 deletions.
24 changes: 0 additions & 24 deletions rhinocommon/cs/SampleCsEto/Properties/AssemblyInfo.cs
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,6 @@
[assembly: PlugInDescription(DescriptionType.WebSite, "http://www.rhino3d.com/")]
[assembly: PlugInDescription(DescriptionType.Icon, "SampleCsEto.Resources.SampleCs.ico")]

// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("SampleCsEto")] // Plug-In title is extracted from this
[assembly: AssemblyDescription("RhinoCommon Sample - SampleCsEto")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Robert McNeel & Associates")]
[assembly: AssemblyProduct("SampleCsEto")]
[assembly: AssemblyCopyright("Copyright © 2017, Robert McNeel & Associates")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
Expand All @@ -33,16 +22,3 @@

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("152aa1ba-306b-402b-98ee-1cf04409ff7f")] // This will also be the Guid of the Rhino plug-in

// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("6.0.0.0")]
[assembly: AssemblyFileVersion("6.0.0.0")]
20 changes: 20 additions & 0 deletions rhinocommon/cs/SampleCsEto/Properties/launchSettings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"profiles": {
"Rhino 8 netcore": {
"commandName": "Executable",
"executablePath": "C:\\Program Files\\Rhino 8\\System\\Rhino.exe",
"commandLineArgs": "/netcore",
"environmentVariables": {
"RHINO_PACKAGE_DIRS": "$(ProjectDir)$(OutputPath)\\"
}
},
"Rhino 8 netfx": {
"commandName": "Executable",
"executablePath": "C:\\Program Files\\Rhino 8\\System\\Rhino.exe",
"commandLineArgs": "/netfx",
"environmentVariables": {
"RHINO_PACKAGE_DIRS": "$(ProjectDir)$(OutputPath)\\"
}
}
}
}
120 changes: 21 additions & 99 deletions rhinocommon/cs/SampleCsEto/SampleCsEto.csproj
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,114 +1,36 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug64</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>8.0.30703</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{CD962975-5E0A-4BB7-AF01-ABD4A9E18AAC}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>SampleCsEto</RootNamespace>
<AssemblyName>SampleCsEto</AssemblyName>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<IsWebBootstrapper>false</IsWebBootstrapper>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\bin\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisIgnoreBuiltInRules>false</CodeAnalysisIgnoreBuiltInRules>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>..\bin\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
<TargetFrameworks>net7.0;net48</TargetFrameworks>
<EnableDynamicLoading>true</EnableDynamicLoading>
<Version>8.0</Version>
<Title>SampleCsEto</Title>
<Description>RhinoCommon Sample - SampleCsEto</Description>
<Company>Robert McNeel &amp; Associates</Company>
<Copyright>Copyright © 2024, Robert McNeel &amp; Associates</Copyright>
<TargetExt>.rhp</TargetExt>
<NoWarn>NU1701</NoWarn>
</PropertyGroup>

<ItemGroup>
<Reference Include="Eto">
<HintPath>C:\Program Files\Rhino 7\System\Eto.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="Rhino.UI">
<HintPath>C:\Program Files\Rhino 7\System\Rhino.UI.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="RhinoCommon">
<HintPath>C:\Program Files\Rhino 7\System\RhinoCommon.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="Microsoft.CSharp" />
<PackageReference Include="RhinoCommon" Version="8.0.23304.9001" ExcludeAssets="runtime" />
<PackageReference Include="System.Drawing.Common" Version="7.0.0" ExcludeAssets="runtime" />
<PackageReference Include="System.Resources.Extensions" Version="7.0.0" ExcludeAssets="runtime" />
</ItemGroup>

<ItemGroup>
<Compile Include="Commands\SampleCsEtoCoffee.cs" />
<Compile Include="Commands\SampleCsEtoCommand.cs" />
<Compile Include="Commands\SampleCsEtoModalDialogCommand.cs" />
<Compile Include="Commands\SampleCsEtoModelessFormCommand.cs" />
<Compile Include="Commands\SampleCsEtoOrderCurvesCommand.cs" />
<Compile Include="Commands\SampleCsEtoPanelCommand.cs" />
<Compile Include="Commands\SampleCsEtoRebuildCurve.cs" />
<Compile Include="Commands\SampleCsEtoSemiModalDialogCommand.cs" />
<Compile Include="Commands\SampleCsEtoViewportCommand.cs" />
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<Compile Update="Properties\Resources.Designer.cs">
<DesignTime>True</DesignTime>
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="SampleCsEtoPlugIn.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Views\SampleCsEtoHelloWorld.cs" />
<Compile Include="Views\SampleCsEtoModalDialog.cs" />
<Compile Include="Views\SampleCsEtoModelessForm.cs" />
<Compile Include="Views\SampleCsEtoOptionsPage.cs" />
<Compile Include="Views\SampleCsEtoPanel.cs" />
<Compile Include="Views\SampleCsEtoPropertiesPage.cs" />
<Compile Include="Views\SampleCsEtoSemiModalDialog.cs" />
</ItemGroup>

<ItemGroup>
<EmbeddedResource Include="Properties\Resources.resx">
<EmbeddedResource Update="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
<EmbeddedResource Include="Resources\SampleCsEtoPanel.ico" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="Resources\SampleCsEtoPanel.png" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="Resources\SampleCs.ico" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
<PropertyGroup>
<PostBuildEvent>Copy "$(TargetPath)" "$(TargetDir)$(ProjectName).rhp"
Erase "$(TargetPath)"</PostBuildEvent>
</PropertyGroup>
<PropertyGroup>
<FallbackCulture>en-US</FallbackCulture>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<StartProgram>c:\Program Files\Rhinoceros 5 (64-bit)\System\Rhino.exe</StartProgram>
<StartArguments>
</StartArguments>
<StartAction>Program</StartAction>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>

</Project>

0 comments on commit 994269a

Please sign in to comment.