private void CreateDocumentLayoutItem(LayoutDocument contentToAttach)
        {
            if (_layoutItems.Any(item => Equals(item.LayoutElement, contentToAttach)))
                return;

            var layoutItem = new LayoutDocumentItem();
            layoutItem.Attach(contentToAttach);
            ApplyStyleToLayoutItem(layoutItem);
            _layoutItems.Add(layoutItem);

            if (contentToAttach?.Content is UIElement)
            {
                InternalAddLogicalChild(contentToAttach.Content);
            }
        }
 protected void SetDocuments(LayoutDocumentItem[] value)
 {
     SetValue(DocumentsPropertyKey, value);
 }
 private void InternalSetSelectedDocument(LayoutDocumentItem documentToSelect)
 {
     _internalSetSelectedDocument = true;
     SelectedDocument = documentToSelect;
     _internalSetSelectedDocument = false;
 }
Ejemplo n.º 4
0
 private void InternalSetSelectedDocument(LayoutDocumentItem documentToSelect)
 {
     _internalSetSelectedDocument = true;
     SelectedDocument             = documentToSelect;
     _internalSetSelectedDocument = false;
 }