commit
182d02a793
7 changed files with 44 additions and 27 deletions
|
|
@ -882,6 +882,9 @@ namespace MatterHackers.MatterControl
|
|||
Icons.Add(typeof(SelectionGroupObject3D), groupIconSource);
|
||||
}
|
||||
|
||||
// register legacy types so they still show, they don't have ui to create so they don't have icons set dynamically
|
||||
Icons.Add(typeof(AlignObject3D), (theme) => StaticData.Instance.LoadIcon("align_left_dark.png", 16, 16).SetToColor(theme.TextColor).SetPreMultiply());
|
||||
|
||||
// image operations
|
||||
PrimaryOperations.Add(typeof(ImageObject3D), new List<SceneOperation> { SceneOperations.ById("ImageConverter"), SceneOperations.ById("ImageToPath"), });
|
||||
|
||||
|
|
@ -919,7 +922,6 @@ namespace MatterHackers.MatterControl
|
|||
PrimaryOperations.Add(typeof(Object3D), new List<SceneOperation> { SceneOperations.ById("Scale") });
|
||||
|
||||
Icons.Add(typeof(ImageObject3D), (theme) => StaticData.Instance.LoadIcon("image_converter.png", 16, 16).SetToColor(theme.TextColor).SetPreMultiply());
|
||||
// Icons.Add(typeof(CubeObject3D), (theme) => StaticData.Instance.LoadIcon("image_converter.png", 16, 16).SetToColor(theme.TextColor).SetPreMultiply());
|
||||
}
|
||||
|
||||
private static SceneOperation CombineOperation()
|
||||
|
|
|
|||
|
|
@ -176,9 +176,9 @@ namespace MatterHackers.MatterControl
|
|||
// TODO: Wire up limits for thumbnail generation. If content is too big, return null allowing the thumbnail to fall back to content default
|
||||
object3D = await contentModel.CreateContent();
|
||||
}
|
||||
else if (libraryItem is ILibraryObject3D)
|
||||
else if (libraryItem is ILibraryObject3D libraryObject3D)
|
||||
{
|
||||
object3D = await (libraryItem as ILibraryObject3D)?.GetObject3D(null);
|
||||
object3D = await libraryObject3D.GetObject3D(null);
|
||||
}
|
||||
|
||||
if (object3D == null)
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
Subproject commit 8dd82c825266791e6d51461bdf4de83df238dc6e
|
||||
Subproject commit 39d47369081d0434eb7ae0610bc76b71c4e0c210
|
||||
|
|
@ -27,12 +27,8 @@ of the authors and should not be interpreted as representing official policies,
|
|||
either expressed or implied, of the FreeBSD Project.
|
||||
*/
|
||||
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using MatterHackers.Agg.UI;
|
||||
using MatterHackers.GuiAutomation;
|
||||
using MatterHackers.MatterControl.PartPreviewWindow;
|
||||
using MatterHackers.MatterControl.PrintQueue;
|
||||
using NUnit.Framework;
|
||||
using TestInvoker;
|
||||
|
||||
|
|
|
|||
|
|
@ -518,13 +518,6 @@ namespace MatterHackers.MatterControl.Tests.Automation
|
|||
|
||||
var printer = testRunner.FirstPrinter();
|
||||
|
||||
// Wait for printing to complete
|
||||
var printFinishedResetEvent = new AutoResetEvent(false);
|
||||
printer.Connection.PrintFinished += (s, e) =>
|
||||
{
|
||||
printFinishedResetEvent.Set();
|
||||
};
|
||||
|
||||
testRunner.StartPrint(printer)
|
||||
.ScrollIntoView("Extrusion Multiplier NumberEdit")
|
||||
.ScrollIntoView("Feed Rate NumberEdit");
|
||||
|
|
@ -552,14 +545,13 @@ namespace MatterHackers.MatterControl.Tests.Automation
|
|||
|
||||
testRunner.ResumePrint();
|
||||
|
||||
// Wait up to 60 seconds for the print to finish
|
||||
printFinishedResetEvent.WaitOne(60 * 1000);
|
||||
// Wait up to 60 seconds for the print to finish
|
||||
testRunner.WaitForPrintFinished(printer, 60);
|
||||
|
||||
// Values should match entered values
|
||||
ConfirmExpectedSpeeds(testRunner, targetExtrusionRate, targetFeedRate, "After print finished");
|
||||
// Values should match entered values
|
||||
ConfirmExpectedSpeeds(testRunner, targetExtrusionRate, targetFeedRate, "After print finished");
|
||||
|
||||
testRunner.WaitForPrintFinished(printer)
|
||||
.StartPrint(printer) // Restart the print
|
||||
testRunner.StartPrint(printer) // Restart the print
|
||||
.Delay(1);
|
||||
|
||||
// Values should match entered values
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@ using System.ComponentModel.DataAnnotations;
|
|||
using System.Linq;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using TestInvoker;
|
||||
|
||||
namespace MatterControl.Tests.MatterControl
|
||||
{
|
||||
|
|
@ -393,7 +394,7 @@ namespace MatterControl.Tests.MatterControl
|
|||
|
||||
var copy = cubeA1.Clone() as CubeObject3D;
|
||||
|
||||
Assert.AreEqual(10, copy.Width.Expression, "10");
|
||||
Assert.AreEqual("10", copy.Width.Expression, "10");
|
||||
Assert.AreEqual(10, copy.GetAxisAlignedBoundingBox().XSize, .001);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,13 +1,39 @@
|
|||
using System;
|
||||
/*
|
||||
Copyright (c) 2022, Lars Brubaker
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are met:
|
||||
|
||||
1. Redistributions of source code must retain the above copyright notice, this
|
||||
list of conditions and the following disclaimer.
|
||||
2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
this list of conditions and the following disclaimer in the documentation
|
||||
and/or other materials provided with the distribution.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
||||
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
|
||||
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
|
||||
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
||||
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
The views and conclusions contained in the software and documentation are those
|
||||
of the authors and should not be interpreted as representing official policies,
|
||||
either expressed or implied, of the FreeBSD Project.
|
||||
*/
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using MatterHackers.Agg;
|
||||
using MatterHackers.Agg.Platform;
|
||||
using MatterHackers.MatterControl;
|
||||
using MatterHackers.MatterControl.SlicerConfiguration;
|
||||
using MatterHackers.MatterControl.Tests.Automation;
|
||||
using Newtonsoft.Json;
|
||||
using NUnit.Framework;
|
||||
using TestInvoker;
|
||||
|
||||
|
|
@ -266,7 +292,7 @@ M300 S3000 P30 ; Resume Tone";
|
|||
}
|
||||
|
||||
|
||||
[Test, ChildProcessTest]
|
||||
[Test]
|
||||
public void LayerGCodeHasExpectedValue()
|
||||
{
|
||||
// Verifies "layer_gcode" is expected value: "; LAYER:[layer_num]"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue