public DependencyObjectViewModel(
            VisualTreeViewModel treeModel,
            TreeItemViewModel parent,
            DependencyObject model)
            : base(treeModel, parent)
        {
            this.Model = model;

            if (!Equals(
                    Model.GetType().GetTypeInfo().Assembly,
                    typeof(FrameworkElement).GetTypeInfo().Assembly))
            {
                this.FontWeight = FontWeights.Bold;
            }

            this.Children.Add(new StubTreeItemViewModel(this.TreeModel, this));

            var fe = model as FrameworkElement;

            if (fe != null)
            {
                _name = fe.Name;
            }

            if (!(model is UIElement) ||
                !model.GetDescendants().Any())
            {
                this.Children.Clear();
            }

#pragma warning disable 4014
            this.RefreshCommand = new RelayCommand(() => RefreshAsync());
#pragma warning restore 4014
        }
 public TreeItemViewModel(
     VisualTreeViewModel treeModel,
     TreeItemViewModel parent)
 {
     this.TreeModel = treeModel;
     this.Parent    = parent;
 }
 public TreeItemViewModel(
     VisualTreeViewModel treeModel,
     TreeItemViewModel parent)
 {
     this.TreeModel = treeModel;
     this.Parent = parent;
 }