Allowing combine to work on a single item if it has multiple meshes.

This commit is contained in:
LarsBrubaker 2018-12-31 07:57:34 -08:00
parent cb6085a7b5
commit 4521b07459
3 changed files with 41 additions and 4 deletions

View file

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