Merge pull request #3611 from jlewin/master
Add C5 NuGet to automation tests, add Dremel OemUrl
This commit is contained in:
commit
7a7c05d04c
7 changed files with 61 additions and 5 deletions
|
|
@ -27,25 +27,72 @@ of the authors and should not be interpreted as representing official policies,
|
|||
either expressed or implied, of the FreeBSD Project.
|
||||
*/
|
||||
|
||||
using System.Collections.Generic;
|
||||
using MatterHackers.Agg.UI;
|
||||
using MatterHackers.DataConverters3D;
|
||||
using MatterHackers.DataConverters3D.UndoCommands;
|
||||
using MatterHackers.MatterControl.CustomWidgets;
|
||||
using MatterHackers.MatterControl.DesignTools.Operations;
|
||||
using System.Collections.Generic;
|
||||
using MatterHackers.Localizations;
|
||||
|
||||
namespace MatterHackers.MatterControl.DesignTools
|
||||
{
|
||||
public class ComponentObject3D : Object3D, IVisualLeafNode
|
||||
{
|
||||
public bool Finalized { get; set; } = true;
|
||||
|
||||
public ComponentObject3D()
|
||||
{
|
||||
}
|
||||
|
||||
public ComponentObject3D(IEnumerable<IObject3D> children)
|
||||
: base (children)
|
||||
: base(children)
|
||||
{
|
||||
}
|
||||
|
||||
public override bool CanApply => Finalized;
|
||||
public bool Finalized { get; set; } = true;
|
||||
public List<string> SurfacedEditors { get; set; } = new List<string>();
|
||||
|
||||
public override void Apply(UndoBuffer undoBuffer)
|
||||
{
|
||||
// we want to end up with just a group of all the visible mesh objects
|
||||
using (RebuildLock())
|
||||
{
|
||||
List<IObject3D> newChildren = new List<IObject3D>();
|
||||
|
||||
// push our matrix into a copy of our visible children
|
||||
foreach (var child in this.VisibleMeshes())
|
||||
{
|
||||
var meshOnlyItem = new Object3D();
|
||||
meshOnlyItem.Matrix = child.WorldMatrix(this);
|
||||
meshOnlyItem.Color = child.WorldColor(this);
|
||||
meshOnlyItem.MaterialIndex = child.WorldMaterialIndex(this);
|
||||
meshOnlyItem.OutputType = child.WorldOutputType(this);
|
||||
meshOnlyItem.Mesh = child.Mesh;
|
||||
meshOnlyItem.Name = "Mesh".Localize();
|
||||
newChildren.Add(meshOnlyItem);
|
||||
}
|
||||
|
||||
if(newChildren.Count > 1)
|
||||
{
|
||||
var group = new GroupObject3D();
|
||||
group.Name = this.Name;
|
||||
group.Children.Modify(list =>
|
||||
{
|
||||
list.AddRange(newChildren);
|
||||
});
|
||||
newChildren.Clear();
|
||||
newChildren.Add(group);
|
||||
}
|
||||
else if(newChildren.Count == 1)
|
||||
{
|
||||
newChildren[0].Name = this.Name;
|
||||
}
|
||||
|
||||
// and replace us with the children
|
||||
undoBuffer.AddAndDo(new ReplaceCommand(new List<IObject3D> { this }, newChildren));
|
||||
}
|
||||
|
||||
Invalidate(new InvalidateArgs(this, InvalidateType.Content, undoBuffer));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -6,6 +6,7 @@
|
|||
"BeeVeryCreative": "https://beeverycreative.com/",
|
||||
"Blue Eagle Labs": "https://www.blueeaglelabs.com/",
|
||||
"Deezmaker": "http://deezmaker.com/",
|
||||
"Dremel": "http://www.dremel.com/",
|
||||
"FlashForge": "http://www.flashforge.com/",
|
||||
"gCreate": "http://www.gcreate.com/",
|
||||
"IRA3D": "",
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
Subproject commit 0aa034ed886a837411ffc45ac7dd5eb0abf051ac
|
||||
Subproject commit be8e29dd6bbfd8fe6f2c2064171211c9cbf0c067
|
||||
|
|
@ -33,6 +33,9 @@
|
|||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="C5, Version=2.5.0.0, Culture=neutral, PublicKeyToken=282361b99ded7e8e, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\packages\C5.2.5.3\lib\net45\C5.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\packages\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
<Private>True</Private>
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="C5" version="2.5.3" targetFramework="net471" />
|
||||
<package id="Newtonsoft.Json" version="9.0.1" targetFramework="net45" />
|
||||
<package id="NUnit" version="3.9.0" targetFramework="net461" />
|
||||
<package id="NUnit.ApplicationDomain" version="11.0.0" targetFramework="net461" />
|
||||
|
|
|
|||
|
|
@ -37,6 +37,9 @@
|
|||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="C5, Version=2.5.0.0, Culture=neutral, PublicKeyToken=282361b99ded7e8e, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\packages\C5.2.5.3\lib\net45\C5.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\packages\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
<Private>True</Private>
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="C5" version="2.5.3" targetFramework="net471" />
|
||||
<package id="Newtonsoft.Json" version="9.0.1" targetFramework="net45" />
|
||||
<package id="NUnit" version="3.9.0" targetFramework="net461" />
|
||||
<package id="NUnit.ApplicationDomain" version="11.0.0" targetFramework="net461" />
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue