//-------------------------------------------------------------------------------------------------- bool _EnsureAisObject() { if (_AisShape != null) { return(true); } if ((_ShapeSource == null) || (AisContext == null)) { return(false); } var brep = OverrideBrep ?? _ShapeSource.GetTransformedBRep(); if (brep == null) { return(false); } _AisShape = new AIS_Shape(brep); _UpdatePresentation(); _UpdateInteractivityStatus(); if (WorkspaceController.Selection.SelectedEntities.Contains(_ShapeSource) && !IsHidden) { AisContext.AddOrRemoveSelected(_AisShape, false); } return(true); }