public static IRenderer GetRendererFromGuid(this Guid guid) { if (GlobalModels.HasModel(guid)) { PObject model = GlobalModels.GetModel <PObject>(guid); return(model.GetRenderer()); } return(null); }
private void LoadElementRenderer(PObject parent, PObject model) { var visual = RendererManager.CreateVisualRendererFromModel(model); if (visual == null) { return; } IRenderer parentRenderer = parent.GetRenderer(); IRenderer modelRenderer = model.GetRenderer(); // Create Renderer LoadRendererCore(modelRenderer); // Add to storyboard AddElement(parentRenderer.Element, visual); }