Getting subtract object to work as source

This commit is contained in:
LarsBrubaker 2019-02-12 08:05:52 -08:00 committed by Lars Brubaker
parent b73c4e5f63
commit 7598c8bf9c
3 changed files with 15 additions and 11 deletions

View file

@ -691,7 +691,11 @@ namespace MatterHackers.MatterControl
TitleResolver = () => "Subtract".Localize(),
Action = (sceneContext) => new SubtractObject3D_2().WrapSelectedItemAndSelect(sceneContext.Scene),
Icon = AggContext.StaticData.LoadIcon("subtract.png").SetPreMultiply(),
IsEnabled = (scene) => scene.SelectedItem is SelectionGroupObject3D,
IsEnabled = (scene) =>
{
var selectedItem = scene.SelectedItem;
return selectedItem != null && selectedItem.VisibleMeshes().Count() > 1;
},
},
new SceneSelectionOperation()
{