Skip to content

Commit

Permalink
Added SampleCsAddGroupUserData.cs, some missing AssemblyInfo.cs files.
Browse files Browse the repository at this point in the history
  • Loading branch information
dalefugier committed Sep 16, 2024
1 parent 97c9e7b commit 592fd4c
Show file tree
Hide file tree
Showing 4 changed files with 72 additions and 3 deletions.
18 changes: 18 additions & 0 deletions rhinocommon/cs/SampleCsEventWatcher/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
using Rhino.PlugIns;
using System.Reflection;
using System.Runtime.InteropServices;

[assembly: PlugInDescription(DescriptionType.Address, "146 North Canal Street, Suite 320\r\nSeattle, WA 98103")]
[assembly: PlugInDescription(DescriptionType.Country, "United States")]
[assembly: PlugInDescription(DescriptionType.Email, "[email protected]")]
[assembly: PlugInDescription(DescriptionType.Phone, "206-545-6877")]
[assembly: PlugInDescription(DescriptionType.Fax, "206-545-7321")]
[assembly: PlugInDescription(DescriptionType.Organization, "Robert McNeel & Associates")]
[assembly: PlugInDescription(DescriptionType.UpdateUrl, "https://github.com/mcneel/rhino-developer-samples")]
[assembly: PlugInDescription(DescriptionType.WebSite, "https://github.com/mcneel/rhino-developer-samples")]
[assembly: PlugInDescription(DescriptionType.Icon, "SampleCsEventWatcher.Resources.SampleCs.ico")]

[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]
[assembly: Guid("934955FB-33BB-4F6C-9F9E-9B0927854AAE")]
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
using Rhino;
using Rhino.Commands;

namespace SampleCsUserData.Commands
{
public class SampleCsAddGroupUserData : Command
{
public override string EnglishName => "SampleCsAddGroupUserData";

protected override Result RunCommand(RhinoDoc doc, RunMode mode)
{
var group = doc.Groups.FindIndex(0);
if (null == group)
{
RhinoApp.WriteLine("No groups found in the document.");
return Result.Success;
}

var ud = group.UserData.Find(typeof(SampleCsUserDataObject)) as SampleCsUserDataObject;
if (null == ud)
{
ud = new SampleCsUserDataObject { Notes = "Hello Rhino Group!" };
group.UserData.Add(ud);
RhinoApp.WriteLine("{0} added", ud.Description);
}
else
{
RhinoApp.WriteLine("{0} = {1}", ud.Description, ud.Notes);
}

return Result.Success;
}
}
}
18 changes: 18 additions & 0 deletions rhinocommon/cs/SampleCsUserData/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
using Rhino.PlugIns;
using System.Reflection;
using System.Runtime.InteropServices;

[assembly: PlugInDescription(DescriptionType.Address, "146 North Canal Street, Suite 320\r\nSeattle, WA 98103")]
[assembly: PlugInDescription(DescriptionType.Country, "United States")]
[assembly: PlugInDescription(DescriptionType.Email, "[email protected]")]
[assembly: PlugInDescription(DescriptionType.Phone, "206-545-6877")]
[assembly: PlugInDescription(DescriptionType.Fax, "206-545-7321")]
[assembly: PlugInDescription(DescriptionType.Organization, "Robert McNeel & Associates")]
[assembly: PlugInDescription(DescriptionType.UpdateUrl, "https://github.com/mcneel/rhino-developer-samples")]
[assembly: PlugInDescription(DescriptionType.WebSite, "https://github.com/mcneel/rhino-developer-samples")]
[assembly: PlugInDescription(DescriptionType.Icon, "SampleCsUserData.Resources.SampleCs.ico")]

[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]
[assembly: Guid("8A62C7AE-3C24-4151-BCD0-AAB36C7DCA8B")]
5 changes: 2 additions & 3 deletions rhinocommon/cs/SamplesCs.sln
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.8.34408.163
Expand Down Expand Up @@ -29,11 +28,11 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SampleCsTest2", "SampleCsSh
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SampleCsSkin", "SampleCsSkin\SampleCsSkin.csproj", "{4E0FCE1B-4577-4F25-86FC-2F1526D2C7CB}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SampleCsUserData", "SampleCsUserData\SampleCsUserData.csproj", "{444482E8-CB8F-4A79-87A8-9C3FCBCC7B16}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SampleCsUserData", "SampleCsUserData\SampleCsUserData.csproj", "{444482E8-CB8F-4A79-87A8-9C3FCBCC7B16}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SampleCsWpf", "SampleCsWpf\SampleCsWpf.csproj", "{098AF3EE-CF77-4FEF-859B-B3BC22C7336A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SampleCsEto", "SampleCsEto\SampleCsEto.csproj", "{CD962975-5E0A-4BB7-AF01-ABD4A9E18AAC}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SampleCsEto", "SampleCsEto\SampleCsEto.csproj", "{CD962975-5E0A-4BB7-AF01-ABD4A9E18AAC}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SampleCsCollapsibleSectionETOUI", "SampleCsCollapsibleSectionETO_UI\SampleCsCollapsibleSectionETOUI.csproj", "{D36880D5-3106-4D36-A9AB-E446E5C5781D}"
EndProject
Expand Down

0 comments on commit 592fd4c

Please sign in to comment.