-
Notifications
You must be signed in to change notification settings - Fork 334
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added SampleCsAddGroupUserData.cs, some missing AssemblyInfo.cs files.
- Loading branch information
1 parent
97c9e7b
commit 592fd4c
Showing
4 changed files
with
72 additions
and
3 deletions.
There are no files selected for viewing
18 changes: 18 additions & 0 deletions
18
rhinocommon/cs/SampleCsEventWatcher/Properties/AssemblyInfo.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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")] |
34 changes: 34 additions & 0 deletions
34
rhinocommon/cs/SampleCsUserData/Commands/SampleCsAddGroupUserData.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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
18
rhinocommon/cs/SampleCsUserData/Properties/AssemblyInfo.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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")] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters