diff --git a/Community.CsharpSqlite/Community.CsharpSqlite.csproj b/Community.CsharpSqlite/Community.CsharpSqlite.csproj
index 3e709e6b5..367becdcb 100644
--- a/Community.CsharpSqlite/Community.CsharpSqlite.csproj
+++ b/Community.CsharpSqlite/Community.CsharpSqlite.csproj
@@ -16,7 +16,7 @@
-
+
diff --git a/MatterControl.Printing/MatterControl.Printing.csproj b/MatterControl.Printing/MatterControl.Printing.csproj
index 68103a912..f76342677 100644
--- a/MatterControl.Printing/MatterControl.Printing.csproj
+++ b/MatterControl.Printing/MatterControl.Printing.csproj
@@ -12,7 +12,7 @@
-
+
diff --git a/MatterControl.SLA/MatterControl.SLA.csproj b/MatterControl.SLA/MatterControl.SLA.csproj
index e01aa291d..e3955a7d3 100644
--- a/MatterControl.SLA/MatterControl.SLA.csproj
+++ b/MatterControl.SLA/MatterControl.SLA.csproj
@@ -12,7 +12,7 @@
-
+
diff --git a/MatterControl.csproj b/MatterControl.csproj
index a6629da9d..14760918c 100644
--- a/MatterControl.csproj
+++ b/MatterControl.csproj
@@ -135,13 +135,13 @@
- 18.0.0
+ 27.2.1
- 5.2.7
+ 5.2.9
- 5.12.0
+ 5.13.0
1.0.2-beta1
diff --git a/MatterControlLib/ApplicationView/SceneOperations.cs b/MatterControlLib/ApplicationView/SceneOperations.cs
index e97516c40..0627282fb 100644
--- a/MatterControlLib/ApplicationView/SceneOperations.cs
+++ b/MatterControlLib/ApplicationView/SceneOperations.cs
@@ -754,6 +754,9 @@ namespace MatterHackers.MatterControl
ArrangeAllPartsOperation(),
new SceneSelectionSeparator(),
LayFlatOperation(),
+#if DEBUG
+ RebuildOperation(),
+#endif
GroupOperation(),
UngroupOperation(),
new SceneSelectionSeparator(),
@@ -1174,6 +1177,42 @@ namespace MatterHackers.MatterControl
};
}
+ private static SceneOperation RebuildOperation()
+ {
+ return new SceneOperation("Rebuild")
+ {
+ TitleGetter = () => "Rebuild".Localize(),
+ Action = (sceneContext) =>
+ {
+ var scene = sceneContext.Scene;
+ var selectedItem = scene.SelectedItem;
+ if (selectedItem != null)
+ {
+ try
+ {
+ var updateItems = SheetObject3D.SortAndLockUpdateItems(selectedItem.Parent, (item) =>
+ {
+ if (item == selectedItem || item.Parent == selectedItem)
+ {
+ // don't process this
+ return false;
+ }
+ return true;
+ }, false);
+
+ SheetObject3D.SendInvalidateInRebuildOrder(updateItems, InvalidateType.Properties, null);
+ }
+ catch
+ {
+ }
+ }
+ },
+ HelpTextGetter = () => "At least 1 part must be selected".Localize().Stars(),
+ IsEnabled = (sceneContext) => sceneContext.Scene.SelectedItem != null,
+ Icon = (theme) => StaticData.Instance.LoadIcon("update.png", 16, 16).SetToColor(theme.TextColor).SetPreMultiply(),
+ };
+ }
+
private static SceneOperation LinearArrayOperation()
{
return new SceneOperation("Linear Array")
diff --git a/MatterControlLib/DesignTools/Operations/ArrayObject3D.cs b/MatterControlLib/DesignTools/Operations/ArrayObject3D.cs
index 628e66fa0..3e807d75e 100644
--- a/MatterControlLib/DesignTools/Operations/ArrayObject3D.cs
+++ b/MatterControlLib/DesignTools/Operations/ArrayObject3D.cs
@@ -111,7 +111,7 @@ namespace MatterHackers.MatterControl.DesignTools.Operations
// process everything else
return true;
- });
+ }, true);
var runningInterval = SheetObject3D.SendInvalidateInRebuildOrder(updateItems, InvalidateType.Properties);
diff --git a/MatterControlLib/DesignTools/Sheets/SheetObject3D.cs b/MatterControlLib/DesignTools/Sheets/SheetObject3D.cs
index 56f94a184..d121ce648 100644
--- a/MatterControlLib/DesignTools/Sheets/SheetObject3D.cs
+++ b/MatterControlLib/DesignTools/Sheets/SheetObject3D.cs
@@ -132,7 +132,7 @@ namespace MatterHackers.MatterControl.DesignTools
}
}
- public static List SortAndLockUpdateItems(IObject3D root, Func includeObject)
+ public static List SortAndLockUpdateItems(IObject3D root, Func includeObject, bool checkForExpression)
{
var requiredUpdateItems = new Dictionary();
foreach (var child in root.Descendants())
@@ -146,8 +146,8 @@ namespace MatterHackers.MatterControl.DesignTools
depthToThis++;
parent = parent.Parent;
}
-
- AddItemsRequiringUpdateToDictionary(child, requiredUpdateItems, depthToThis, includeObject);
+
+ AddItemsRequiringUpdateToDictionary(child, requiredUpdateItems, depthToThis, includeObject, checkForExpression);
}
}
@@ -181,13 +181,13 @@ namespace MatterHackers.MatterControl.DesignTools
}
return true;
- });
+ }, true);
SendInvalidateInRebuildOrder(updateItems, InvalidateType.SheetUpdated, this);
}
public static RunningInterval SendInvalidateInRebuildOrder(List updateItems,
- InvalidateType sheetUpdated,
+ InvalidateType invalidateType,
IObject3D sender = null)
{
// and send the invalidate
@@ -214,7 +214,7 @@ namespace MatterHackers.MatterControl.DesignTools
updateItem.rebuildLock.Dispose();
updateItem.rebuildLock = null;
var updateSender = sender == null ? updateItem.item : sender;
- updateItem.item.Invalidate(new InvalidateArgs(updateSender, sheetUpdated));
+ updateItem.item.Invalidate(new InvalidateArgs(updateSender, invalidateType));
}
}
}
@@ -250,17 +250,21 @@ namespace MatterHackers.MatterControl.DesignTools
return runningInterval;
}
- private static void AddItemsRequiringUpdateToDictionary(IObject3D inItem, Dictionary updatedItems, int inDepth, Func includeObject)
+ private static void AddItemsRequiringUpdateToDictionary(IObject3D inItem,
+ Dictionary updatedItems,
+ int inDepth,
+ Func includeObject,
+ bool checkForExpression)
{
// process depth first
foreach(var child in inItem.Children)
{
- AddItemsRequiringUpdateToDictionary(child, updatedItems, inDepth + 1, includeObject);
+ AddItemsRequiringUpdateToDictionary(child, updatedItems, inDepth + 1, includeObject, checkForExpression);
}
var depth2 = inDepth;
if (includeObject(inItem)
- && HasExpressionWithString(inItem, "=", true))
+ && (!checkForExpression || HasExpressionWithString(inItem, "=", true)))
{
var itemToAdd = inItem;
while (itemToAdd != null
diff --git a/MatterControlLib/MatterControlLib.csproj b/MatterControlLib/MatterControlLib.csproj
index 2b666df40..ad004c2b0 100644
--- a/MatterControlLib/MatterControlLib.csproj
+++ b/MatterControlLib/MatterControlLib.csproj
@@ -88,27 +88,27 @@
-
-
+
+
-
-
+
+
-
-
-
+
+
+
-
+
-
+
diff --git a/Submodules/MatterSlice b/Submodules/MatterSlice
index cce755cd9..d30433b04 160000
--- a/Submodules/MatterSlice
+++ b/Submodules/MatterSlice
@@ -1 +1 @@
-Subproject commit cce755cd9c356a96edb641ed515113caa6bf6ad3
+Subproject commit d30433b04424d0af57fa22e0bf8cec077ac41b2a
diff --git a/Submodules/agg-sharp b/Submodules/agg-sharp
index 338231d1f..4af60a982 160000
--- a/Submodules/agg-sharp
+++ b/Submodules/agg-sharp
@@ -1 +1 @@
-Subproject commit 338231d1f1bafe87d200435b065035846e75ca60
+Subproject commit 4af60a9822345f3bf6800ede7d5b6c6948ea0dc9
diff --git a/Tests/MatterControl.AutomationTests/MatterControl.AutomationTests.csproj b/Tests/MatterControl.AutomationTests/MatterControl.AutomationTests.csproj
index c03586734..bdcc92c7d 100644
--- a/Tests/MatterControl.AutomationTests/MatterControl.AutomationTests.csproj
+++ b/Tests/MatterControl.AutomationTests/MatterControl.AutomationTests.csproj
@@ -42,11 +42,11 @@
AnyCPU
-
-
-
+
+
+
- 3.12.0
+ 4.2.1
diff --git a/Tests/MatterControl.Tests/MatterControl.Tests.csproj b/Tests/MatterControl.Tests/MatterControl.Tests.csproj
index 50845c69d..3af225a86 100644
--- a/Tests/MatterControl.Tests/MatterControl.Tests.csproj
+++ b/Tests/MatterControl.Tests/MatterControl.Tests.csproj
@@ -156,11 +156,11 @@
-
-
-
-
-
+
+
+
+
+