From b9c127113aabbce6fc4bd0f82531543bfaf16cea Mon Sep 17 00:00:00 2001 From: Matthew Swaidan Date: Thu, 19 Sep 2019 17:56:09 -0400 Subject: [PATCH 1/9] Adds ListMyProjects component --- .../Management/ListMyProjects.cs | 107 ++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 SpeckleGrasshopper/Management/ListMyProjects.cs diff --git a/SpeckleGrasshopper/Management/ListMyProjects.cs b/SpeckleGrasshopper/Management/ListMyProjects.cs new file mode 100644 index 0000000..eed6830 --- /dev/null +++ b/SpeckleGrasshopper/Management/ListMyProjects.cs @@ -0,0 +1,107 @@ +using System; +using System.Collections.Generic; +using SpeckleCore; +using System.Linq; + +using Grasshopper.Kernel; +using Grasshopper.Kernel.Types; +using Rhino.Geometry; +using SpeckleGrasshopper.Properties; + +namespace SpeckleGrasshopper.Management +{ + //based on dimitrie's ListStreams component + public class ListMyProjects : GH_Component + { + List UserProjects = new List(); + SpeckleApiClient Client = new SpeckleApiClient(); + + Action ExpireComponent; + + public ListMyProjects() + : base("Projects", "Projects", "Lists projects you own or have access to", "Speckle", "Management") + { + SpeckleInitializer.Initialize(); + LocalContext.Init(); + } + + + /// + /// Registers all the input parameters for this component. + /// + protected override void RegisterInputParams(GH_Component.GH_InputParamManager pManager) + { + pManager.AddGenericParameter("Account", "A", "Speckle account you want to retrieve your streams from.", GH_ParamAccess.item); + } + + /// + /// Registers all the output parameters for this component. + /// + protected override void RegisterOutputParams(GH_Component.GH_OutputParamManager pManager) + { + pManager.AddGenericParameter("Projects", "P", "Projects you own or have write access to", GH_ParamAccess.list); + } + + public override void AddedToDocument(GH_Document document) + { + base.AddedToDocument(document); + + ExpireComponent = () => this.ExpireSolution(true); + } + /// + /// This is the method that actually does the work. + /// + /// The DA object is used to retrieve from inputs and store in outputs. + protected override void SolveInstance(IGH_DataAccess DA) + { + Account Account = null; + DA.GetData("Account", ref Account); + + + if (Account == null) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Error, "Could not set the account"); + return; + } + + DA.SetDataList("Projects", UserProjects); + + Client.BaseUrl = Account.RestApi; Client.AuthToken = Account.Token; + Client.ProjectGetAllAsync().ContinueWith(tsk => + { + if (tsk.Result.Success == false) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Error, "There was an error getting the list of projects"); + return; + } + var newProjects = tsk.Result.Resources.ToList(); + var notUpdated = UserProjects.Select(x => x._id).SequenceEqual(newProjects.Select(x => x._id)); + + if (!notUpdated){ + UserProjects = tsk.Result.Resources.ToList(); + Rhino.RhinoApp.MainApplicationWindow.Invoke(ExpireComponent); + } + }); + } + + /// + /// Provides an Icon for the component. + /// + protected override System.Drawing.Bitmap Icon + { + get + { + + return Resources.GenericIconXS; + } + } + + /// + /// Gets the unique ID for this component. Do not change this ID after release. + /// + public override Guid ComponentGuid + { + get { return new Guid("d82e4c2c-dd81-4ff7-bdfd-d15163dc64f7"); } + } + } +} From ced5920e0926ac46e15ded907902e6aa6025ef55 Mon Sep 17 00:00:00 2001 From: Matthew Swaidan Date: Fri, 20 Sep 2019 15:08:19 -0400 Subject: [PATCH 2/9] Right clieck to select a single project --- .../Management/ListMyProjects.cs | 33 +++++++++++++++++-- 1 file changed, 30 insertions(+), 3 deletions(-) diff --git a/SpeckleGrasshopper/Management/ListMyProjects.cs b/SpeckleGrasshopper/Management/ListMyProjects.cs index eed6830..489bf0f 100644 --- a/SpeckleGrasshopper/Management/ListMyProjects.cs +++ b/SpeckleGrasshopper/Management/ListMyProjects.cs @@ -7,6 +7,7 @@ using Grasshopper.Kernel.Types; using Rhino.Geometry; using SpeckleGrasshopper.Properties; +using System.Windows.Forms; namespace SpeckleGrasshopper.Management { @@ -15,7 +16,7 @@ public class ListMyProjects : GH_Component { List UserProjects = new List(); SpeckleApiClient Client = new SpeckleApiClient(); - + Project SelectedProject = null; Action ExpireComponent; public ListMyProjects() @@ -25,6 +26,25 @@ public ListMyProjects() LocalContext.Init(); } + public override void AppendAdditionalMenuItems(ToolStripDropDown menu) + { + base.AppendAdditionalMenuItems(menu); + foreach (Project project in UserProjects) + { + var nameString = ""; + if (project.number != null) { nameString += project.number + " - "; } + nameString += project.Name; + Menu_AppendItem(menu, nameString, (sender, e) => + { + if (SelectedProject == project) + { + SelectedProject = null; + } + else { SelectedProject = project; } + Rhino.RhinoApp.MainApplicationWindow.Invoke(ExpireComponent); + },true, project == SelectedProject ); + } + } /// /// Registers all the input parameters for this component. @@ -39,13 +59,13 @@ protected override void RegisterInputParams(GH_Component.GH_InputParamManager pM /// protected override void RegisterOutputParams(GH_Component.GH_OutputParamManager pManager) { - pManager.AddGenericParameter("Projects", "P", "Projects you own or have write access to", GH_ParamAccess.list); + pManager.AddGenericParameter("Projects", "Ps", "Projects you own or have write access to", GH_ParamAccess.list); + pManager.AddGenericParameter("Selected Project", "P", "Double click this component to select one project", GH_ParamAccess.item); } public override void AddedToDocument(GH_Document document) { base.AddedToDocument(document); - ExpireComponent = () => this.ExpireSolution(true); } /// @@ -64,6 +84,13 @@ protected override void SolveInstance(IGH_DataAccess DA) return; } + if (SelectedProject == null) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Remark, "Right click this component to select a project"); + } + + + DA.SetData("Selected Project", SelectedProject); DA.SetDataList("Projects", UserProjects); Client.BaseUrl = Account.RestApi; Client.AuthToken = Account.Token; From 006cbe8a0bb715f07518d24fb5cd427422e9b9cc Mon Sep 17 00:00:00 2001 From: Matthew Swaidan Date: Fri, 20 Sep 2019 17:03:44 -0400 Subject: [PATCH 3/9] Better error messaging --- SpeckleGrasshopper/Management/ListMyProjects.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SpeckleGrasshopper/Management/ListMyProjects.cs b/SpeckleGrasshopper/Management/ListMyProjects.cs index 489bf0f..b8b8cd9 100644 --- a/SpeckleGrasshopper/Management/ListMyProjects.cs +++ b/SpeckleGrasshopper/Management/ListMyProjects.cs @@ -98,7 +98,7 @@ protected override void SolveInstance(IGH_DataAccess DA) { if (tsk.Result.Success == false) { - AddRuntimeMessage(GH_RuntimeMessageLevel.Error, "There was an error getting the list of projects"); + AddRuntimeMessage(GH_RuntimeMessageLevel.Error, tsk.Result.Message); return; } var newProjects = tsk.Result.Resources.ToList(); From 318584270f4706bdf40e081fd84a1ac59a3dfae2 Mon Sep 17 00:00:00 2001 From: Matthew Swaidan Date: Fri, 20 Sep 2019 17:04:33 -0400 Subject: [PATCH 4/9] Expire when same account is re-connected --- .../Management/ListMyStreams.cs | 34 +++++++++++-------- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/SpeckleGrasshopper/Management/ListMyStreams.cs b/SpeckleGrasshopper/Management/ListMyStreams.cs index e8e7c57..39d5258 100644 --- a/SpeckleGrasshopper/Management/ListMyStreams.cs +++ b/SpeckleGrasshopper/Management/ListMyStreams.cs @@ -15,8 +15,6 @@ public class ListStreams : GH_Component List SharedStreams = new List(); SpeckleApiClient Client = new SpeckleApiClient(); - Account OldAccount; - Action ExpireComponent; public ListStreams( ) : base( "Streams", "Streams", "Lists your existing Speckle streams for a specified account.", "Speckle", "Management" ) @@ -46,27 +44,33 @@ public override void AddedToDocument( GH_Document document ) protected override void SolveInstance( IGH_DataAccess DA ) { - object preAccount = null; Account Account = null; - DA.GetData( 0, ref preAccount ); - - Account = ( ( Account ) preAccount.GetType().GetProperty( "Value" ).GetValue( preAccount, null ) ); + DA.GetData( 0, ref Account ); - if ( Account == null ) + if ( Account == null) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Error, "Couldn't set the account"); return; + } DA.SetDataList( 0, UserStreams ); - - if ( Account == OldAccount ) - return; - - OldAccount = Account; - + Client.BaseUrl = Account.RestApi; Client.AuthToken = Account.Token; Client.StreamsGetAllAsync( "fields=streamId,name,description&isComputedResult=false&deleted=false" ).ContinueWith( tsk => { - UserStreams = tsk.Result.Resources.ToList(); - Rhino.RhinoApp.MainApplicationWindow.Invoke( ExpireComponent ); + if (tsk.Result.Success == false) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Error, tsk.Result.Message); + return; + } + var newStreams = tsk.Result.Resources.ToList(); + var notUpdated = UserStreams.Select(x => x._id).SequenceEqual(newStreams.Select(x => x._id)); + + if (!notUpdated) + { + UserStreams = tsk.Result.Resources.ToList(); + Rhino.RhinoApp.MainApplicationWindow.Invoke(ExpireComponent); + } } ); } From 8ff6256838f6e5aca5cb92c6bad49e834ba4aaff Mon Sep 17 00:00:00 2001 From: Matthew Swaidan Date: Fri, 20 Sep 2019 17:05:24 -0400 Subject: [PATCH 5/9] Adds email to nickname + menuitem --- SpeckleGrasshopper/Management/ListMyAccounts.cs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/SpeckleGrasshopper/Management/ListMyAccounts.cs b/SpeckleGrasshopper/Management/ListMyAccounts.cs index 0b0c853..ff3a5cd 100644 --- a/SpeckleGrasshopper/Management/ListMyAccounts.cs +++ b/SpeckleGrasshopper/Management/ListMyAccounts.cs @@ -73,10 +73,13 @@ public override void AppendAdditionalMenuItems( ToolStripDropDown menu ) foreach ( var account in Accounts ) { - Menu_AppendItem( menu, count++ + ". " + account.ServerName, ( sender, e ) => + string displayName = account.ServerName; + displayName = displayName.Substring(0, 10); + displayName += "... - " + account.Email.Substring(0,10) + "..."; + Menu_AppendItem( menu, count++ + ". " + displayName, ( sender, e ) => { Selected = account; - this.NickName = account.ServerName; + NickName = displayName; Rhino.RhinoApp.MainApplicationWindow.Invoke( ExpireComponent ); }, true ); } From 171ef2dc0bf8369485c397bc56264295fd0313b1 Mon Sep 17 00:00:00 2001 From: Matthew Swaidan Date: Fri, 20 Sep 2019 17:05:47 -0400 Subject: [PATCH 6/9] Add a list of streams to a project --- .../Management/AddStreamsToProject.cs | 138 ++++++++++++++++++ 1 file changed, 138 insertions(+) create mode 100644 SpeckleGrasshopper/Management/AddStreamsToProject.cs diff --git a/SpeckleGrasshopper/Management/AddStreamsToProject.cs b/SpeckleGrasshopper/Management/AddStreamsToProject.cs new file mode 100644 index 0000000..b9a0067 --- /dev/null +++ b/SpeckleGrasshopper/Management/AddStreamsToProject.cs @@ -0,0 +1,138 @@ +using System; +using SpeckleCore; +using System.Collections.Generic; +using System.Linq; +using Grasshopper.Kernel; +using Rhino.Geometry; +using SpeckleGrasshopper.Properties; + +namespace SpeckleGrasshopper.Management +{ + public class AddStreamsToProject : GH_Component + { + /// + /// Initializes a new instance of the AddStreamsToProject class. + /// + + SpeckleApiClient Client = new SpeckleApiClient(); + Action ExpireComponent; + List AddedStreams = new List(); + public AddStreamsToProject() + : base("AddStreamsToProject", "Add Streams","Add a list of streams to a project","Speckle", "Management") + { + + } + + public override void AddedToDocument(GH_Document document) + { + base.AddedToDocument(document); + ExpireComponent = () => this.ExpireSolution(true); + } + + /// + /// Registers all the input parameters for this component. + /// + protected override void RegisterInputParams(GH_Component.GH_InputParamManager pManager) + { + pManager.AddGenericParameter("Account", "A", "Account with project write access", GH_ParamAccess.item); + pManager.AddGenericParameter("Project", "P", "Project to add streams to", GH_ParamAccess.item); + pManager.AddGenericParameter("Streams", "S", "Streams to add", GH_ParamAccess.list); + } + + /// + /// Registers all the output parameters for this component. + /// + protected override void RegisterOutputParams(GH_Component.GH_OutputParamManager pManager) + { + } + + /// + /// This is the method that actually does the work. + /// + /// The DA object is used to retrieve from inputs and store in outputs. + protected override void SolveInstance(IGH_DataAccess DA) + { + var streams = new List(); + Project project = null; + Account account = null; + + DA.GetData("Project", ref project); + DA.GetDataList("Streams", streams); + DA.GetData("Account", ref account); + + if (null == project) { + AddRuntimeMessage(GH_RuntimeMessageLevel.Warning, + "You must connect an account to this component"); + return; + } + + if (null == streams) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Warning, + "You must connect at least one stream to this component"); + return; + } + + if (null == project) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Warning, + "You must connect a project to this component"); + return; + } + + if (null != AddedStreams && AddedStreams.Count > 0) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Remark, "Added " + + AddedStreams.Select(stream => stream.StreamId).ToString() + + "to the project"); + } + + //Do nothing if the project already contains these streams + var streamsToAdd = streams.Where(stream => !project.Streams.Contains(stream.StreamId)).ToList(); + if (streamsToAdd.Count() < 1 ) + { + AddedStreams.Clear(); + return; + } + + project.Streams.AddRange(streamsToAdd.Select(stream => stream.StreamId)); + + Client.BaseUrl = account.RestApi; + Client.AuthToken = account.Token; + + Client.ProjectUpdateAsync(project._id, project).ContinueWith(task => + { + if (task.Result.Success == false) + { + AddRuntimeMessage(GH_RuntimeMessageLevel.Error, task.Result.Message); + return; + } + AddedStreams.Clear(); + AddedStreams.AddRange(streamsToAdd); + Rhino.RhinoApp.MainApplicationWindow.Invoke(ExpireComponent); + }); + + } + + /// + /// Provides an Icon for the component. + /// + protected override System.Drawing.Bitmap Icon + { + get + { + //You can add image files to your project resources and access them like this: + // return Resources.IconForThisComponent; + return Resources.GenericIconXS; + } + } + + /// + /// Gets the unique ID for this component. Do not change this ID after release. + /// + public override Guid ComponentGuid + { + get { return new Guid("6712f7f4-3faa-4d3a-b060-7385966dc5c7"); } + } + } +} From e03c6e13f224d8cb1b7d40d126c27fbc9f97a781 Mon Sep 17 00:00:00 2001 From: Matthew Swaidan Date: Fri, 20 Sep 2019 17:46:15 -0400 Subject: [PATCH 7/9] Handles streams or streamIds --- .../Management/AddStreamsToProject.cs | 52 +++++++++++++++---- 1 file changed, 41 insertions(+), 11 deletions(-) diff --git a/SpeckleGrasshopper/Management/AddStreamsToProject.cs b/SpeckleGrasshopper/Management/AddStreamsToProject.cs index b9a0067..2f81b68 100644 --- a/SpeckleGrasshopper/Management/AddStreamsToProject.cs +++ b/SpeckleGrasshopper/Management/AddStreamsToProject.cs @@ -16,7 +16,7 @@ public class AddStreamsToProject : GH_Component SpeckleApiClient Client = new SpeckleApiClient(); Action ExpireComponent; - List AddedStreams = new List(); + List AddedStreamIds = new List(); public AddStreamsToProject() : base("AddStreamsToProject", "Add Streams","Add a list of streams to a project","Speckle", "Management") { @@ -52,12 +52,14 @@ protected override void RegisterOutputParams(GH_Component.GH_OutputParamManager /// The DA object is used to retrieve from inputs and store in outputs. protected override void SolveInstance(IGH_DataAccess DA) { - var streams = new List(); + //var streams = new List(); + var streamObjects = new List(); + var streamIds = new List(); Project project = null; Account account = null; DA.GetData("Project", ref project); - DA.GetDataList("Streams", streams); + DA.GetDataList("Streams", streamObjects); DA.GetData("Account", ref account); if (null == project) { @@ -66,7 +68,7 @@ protected override void SolveInstance(IGH_DataAccess DA) return; } - if (null == streams) + if (null == streamObjects) { AddRuntimeMessage(GH_RuntimeMessageLevel.Warning, "You must connect at least one stream to this component"); @@ -80,22 +82,50 @@ protected override void SolveInstance(IGH_DataAccess DA) return; } - if (null != AddedStreams && AddedStreams.Count > 0) + foreach (object streamObject in streamObjects) { + if (streamObject is Grasshopper.Kernel.Types.GH_String) + { + var streamId = (streamObject as Grasshopper.Kernel.Types.GH_String).Value; + streamIds.Add(streamId); + continue; + } + if (streamObject is Grasshopper.Kernel.Types.GH_ObjectWrapper) + { + var stream = (SpeckleStream)(streamObject as Grasshopper.Kernel.Types.GH_ObjectWrapper).Value; + if (null != stream) + { + streamIds.Add(stream.StreamId); + continue; + } + AddRuntimeMessage(GH_RuntimeMessageLevel.Error, "This component only works with streamIds or SpeckleStream objects"); + } + AddRuntimeMessage(GH_RuntimeMessageLevel.Error, "This component only works with streamIds or SpeckleStream objects"); + return; + } + + if (null != AddedStreamIds && AddedStreamIds.Count > 0) + { + string addedList = ""; + foreach (string streamId in AddedStreamIds) + { + addedList += streamId + ","; + } + addedList = addedList.Substring(0, addedList.Length - 1); AddRuntimeMessage(GH_RuntimeMessageLevel.Remark, "Added " + - AddedStreams.Select(stream => stream.StreamId).ToString() + + addedList + "to the project"); } //Do nothing if the project already contains these streams - var streamsToAdd = streams.Where(stream => !project.Streams.Contains(stream.StreamId)).ToList(); + var streamsToAdd = streamIds.Where(streamId => !project.Streams.Contains(streamId)).ToList(); if (streamsToAdd.Count() < 1 ) { - AddedStreams.Clear(); + AddedStreamIds.Clear(); return; } - project.Streams.AddRange(streamsToAdd.Select(stream => stream.StreamId)); + project.Streams.AddRange(streamsToAdd); Client.BaseUrl = account.RestApi; Client.AuthToken = account.Token; @@ -107,8 +137,8 @@ protected override void SolveInstance(IGH_DataAccess DA) AddRuntimeMessage(GH_RuntimeMessageLevel.Error, task.Result.Message); return; } - AddedStreams.Clear(); - AddedStreams.AddRange(streamsToAdd); + AddedStreamIds.Clear(); + AddedStreamIds.AddRange(streamsToAdd); Rhino.RhinoApp.MainApplicationWindow.Invoke(ExpireComponent); }); From 8bbf5c53face3d0724de5aa5f174038e24406fdd Mon Sep 17 00:00:00 2001 From: Matthew Swaidan Date: Mon, 23 Sep 2019 12:35:38 -0400 Subject: [PATCH 8/9] Adds icons --- .../Management/AddStreamsToProject.cs | 2 +- .../Management/ListMyAccounts.cs | 2 +- .../Management/ListMyProjects.cs | 2 +- .../Management/ListMyStreams.cs | 2 +- .../Properties/Resources.Designer.cs | 40 ++++++++++++++++++ SpeckleGrasshopper/Properties/Resources.resx | 13 +++++- SpeckleGrasshopper/Resources/Accounts.png | Bin 0 -> 286 bytes .../Resources/AddStreamToProject.png | Bin 0 -> 424 bytes SpeckleGrasshopper/Resources/Projects.png | Bin 0 -> 437 bytes SpeckleGrasshopper/Resources/Streams.png | Bin 0 -> 407 bytes 10 files changed, 55 insertions(+), 6 deletions(-) create mode 100644 SpeckleGrasshopper/Resources/Accounts.png create mode 100644 SpeckleGrasshopper/Resources/AddStreamToProject.png create mode 100644 SpeckleGrasshopper/Resources/Projects.png create mode 100644 SpeckleGrasshopper/Resources/Streams.png diff --git a/SpeckleGrasshopper/Management/AddStreamsToProject.cs b/SpeckleGrasshopper/Management/AddStreamsToProject.cs index 2f81b68..c44a843 100644 --- a/SpeckleGrasshopper/Management/AddStreamsToProject.cs +++ b/SpeckleGrasshopper/Management/AddStreamsToProject.cs @@ -153,7 +153,7 @@ protected override System.Drawing.Bitmap Icon { //You can add image files to your project resources and access them like this: // return Resources.IconForThisComponent; - return Resources.GenericIconXS; + return Resources.AddStreamToProject; } } diff --git a/SpeckleGrasshopper/Management/ListMyAccounts.cs b/SpeckleGrasshopper/Management/ListMyAccounts.cs index ff3a5cd..bde22be 100644 --- a/SpeckleGrasshopper/Management/ListMyAccounts.cs +++ b/SpeckleGrasshopper/Management/ListMyAccounts.cs @@ -102,7 +102,7 @@ protected override System.Drawing.Bitmap Icon { get { - return Resources.GenericIconXS; + return Resources.Accounts; } } diff --git a/SpeckleGrasshopper/Management/ListMyProjects.cs b/SpeckleGrasshopper/Management/ListMyProjects.cs index b8b8cd9..6e5a600 100644 --- a/SpeckleGrasshopper/Management/ListMyProjects.cs +++ b/SpeckleGrasshopper/Management/ListMyProjects.cs @@ -119,7 +119,7 @@ protected override System.Drawing.Bitmap Icon get { - return Resources.GenericIconXS; + return Resources.Projects; } } diff --git a/SpeckleGrasshopper/Management/ListMyStreams.cs b/SpeckleGrasshopper/Management/ListMyStreams.cs index 39d5258..e216d71 100644 --- a/SpeckleGrasshopper/Management/ListMyStreams.cs +++ b/SpeckleGrasshopper/Management/ListMyStreams.cs @@ -78,7 +78,7 @@ protected override System.Drawing.Bitmap Icon { get { - return Resources.GenericIconXS; + return Resources.Streams; } } diff --git a/SpeckleGrasshopper/Properties/Resources.Designer.cs b/SpeckleGrasshopper/Properties/Resources.Designer.cs index 4c45a49..7ebc836 100644 --- a/SpeckleGrasshopper/Properties/Resources.Designer.cs +++ b/SpeckleGrasshopper/Properties/Resources.Designer.cs @@ -60,6 +60,26 @@ internal Resources() { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap Accounts { + get { + object obj = ResourceManager.GetObject("Accounts", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap AddStreamToProject { + get { + object obj = ResourceManager.GetObject("AddStreamToProject", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -180,6 +200,16 @@ internal static System.Drawing.Bitmap play25px { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap Projects { + get { + object obj = ResourceManager.GetObject("Projects", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -219,5 +249,15 @@ internal static System.Drawing.Bitmap SetUserData { return ((System.Drawing.Bitmap)(obj)); } } + + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap Streams { + get { + object obj = ResourceManager.GetObject("Streams", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } } } diff --git a/SpeckleGrasshopper/Properties/Resources.resx b/SpeckleGrasshopper/Properties/Resources.resx index 3650edf..9363390 100644 --- a/SpeckleGrasshopper/Properties/Resources.resx +++ b/SpeckleGrasshopper/Properties/Resources.resx @@ -166,7 +166,16 @@ ..\Resources\icon-01.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\icon-01.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\Accounts.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\AddStreamToProject.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\Projects.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\Streams.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a \ No newline at end of file diff --git a/SpeckleGrasshopper/Resources/Accounts.png b/SpeckleGrasshopper/Resources/Accounts.png new file mode 100644 index 0000000000000000000000000000000000000000..39880b5e2203825cd6bc1debaaa1bfceed649f71 GIT binary patch literal 286 zcmeAS@N?(olHy`uVBq!ia0vp^k|4~%1|*NXY)uAIoCO|{#S9GGLLkg|>2BR0px^~h z7sn8f&g4J;|JyUKWfVS}D-kwrgF^A8FKW^T1_n6^2?-OHA2`#_!^6Y4S?_6F1LuO@ zOB$WHB^LaWp1{hc@<@8Yy`?NRF5gdnIH~?(rFTPPVW?29L literal 0 HcmV?d00001 diff --git a/SpeckleGrasshopper/Resources/AddStreamToProject.png b/SpeckleGrasshopper/Resources/AddStreamToProject.png new file mode 100644 index 0000000000000000000000000000000000000000..7d4139065e86534e01a457f430c444cb7958f6e2 GIT binary patch literal 424 zcmV;Z0ayNsP)P000>X1^@s6#OZ}&00009a7bBm000XT z000XT0n*)m`~Uy}T1iAfR7i=XZ$q6tgAha&xAW^v)w96W7grDn3{L)JMn4N!Tc4lWC5#i7n+3NQl7C`W8I!=U# zd|+jX@302WE0(Vk;ZAjqEC}W`1SQzGYg*{P!Plt`O73b+;-*?@n0Y^&3)m*YP1W8m z?o#fFI>>*c(Gp`pWFjbVQ+?ui3VUl3qkI^s5dN!;cM^_wvLEjxDvZ~;>jS8+&iFH;XcLJ<{jhhl@o+fRL+>&JtK@lqXUN1hl>_eiW z=cR@G1~`43aNmVQyDRf_IL?a;Zb}F|nW4()MdoRjc1F|1zXR8qN6?pmhGdLY@);|w zP)Ra`@*KUN`hQ1aU49J$-zh!y!<1iB8J}xJ?8|Q=I{H*{Hp2Q#bnxFwD*&Ih{GM9G S!wDMz0000P000>X1^@s6#OZ}&00009a7bBm000XT z000XT0n*)m`~Uy}XGugsR7i=nR%h|T-io0(F?7-}VOv?L$1TGSdNa#>=UosMUP^fJmtR#^@4B#_>fRIK4 z?e)!*WKifMfsYN5^fK`zVIm6M8h$9&G@+Yu39$DVlrBQQNSJ`G@p}NtcO;P6G&$II z^Zkwk2*CTzmZY&Jyjf(=&} zUnF$jS@_^O2^D@cTK;C(NHT8M6GF#t=89yQ%hZ?$HyTVE#_w!*629h{{GT9uy1~xB fM7#g3>P000>X1^@s6#OZ}&00009a7bBm000XT z000XT0n*)m`~Uy}Nl8ROR7i>KmN8DlFcgMAQ00~S1aN|=oS@+(WXe`CG1D6W%GN2| zpf@0#fT|auoWNzZkb+|D;-+z%7G=vXWpLu>|NXyT{CrlHC0%3S)=#5s2qeI;#yOuY zCyW2&VU$>c6>!lo=L?8KL_%?;rHKvV+`H{ znb@SRY|s!;%$Ad>wIT=JbJbea82Av1XJD!&YdpJlAe6E2w)OJcxC1uogCtrS6)z`} zR7yr}&}5fSl-QyOLMWbW=GgsgwI|1-%J>_&*U}K~AZXVSSlDDAg`%kbn|kP8CAPYb z+5En``s(^aUtNcAu)5+j%FI!p{C3Ohef>lzs<{t#*jQao$=Z82wn6SG(kL7GK@Io> zZnPwBYQ>Hux4rxn Date: Mon, 23 Sep 2019 18:09:58 +0100 Subject: [PATCH 9/9] adds files to project --- SpeckleGrasshopper/SpeckleGrasshopper.csproj | 2 ++ 1 file changed, 2 insertions(+) diff --git a/SpeckleGrasshopper/SpeckleGrasshopper.csproj b/SpeckleGrasshopper/SpeckleGrasshopper.csproj index 63a9a72..8b443cf 100644 --- a/SpeckleGrasshopper/SpeckleGrasshopper.csproj +++ b/SpeckleGrasshopper/SpeckleGrasshopper.csproj @@ -72,6 +72,8 @@ + +