Making component work better with sheets

This commit is contained in:
Lars Brubaker 2021-09-28 12:55:39 -07:00
parent d19ba09c6d
commit ebefc33e3e
5 changed files with 31 additions and 9 deletions

View file

@ -58,7 +58,24 @@ namespace MatterHackers.MatterControl.DesignTools
public override bool Persistable => ApplicationController.Instance.UserHasPermission(this);
public bool Finalized { get; set; } = true;
private bool _finalizade = true;
public bool Finalized
{
get => _finalizade;
set
{
_finalizade = value;
// on any invalidate ensure that the visibility setting are correct for embedded sheet objects
foreach (var child in this.Descendants())
{
if (child is SheetObject3D)
{
child.Visible = !this.Finalized;
}
}
}
}
public List<string> SurfacedEditors { get; set; } = new List<string>();