Ejemplo n.º 1
0
        public void UpdateSolutionItems()
        {
            SSObject ssObjects = SolutionObjectData.GetSolutionItems();

            rootItem             = new SSObjectViewModel(ssObjects);
            this.solutionObjects = new ReadOnlyCollection <ISSObjectViewModel>(
                new SSObjectViewModel[]
            {
                rootItem
            });
        }
Ejemplo n.º 2
0
        public ObjectTreeViewModel(SSObject ssObjects)
        {
            rootItem             = new SSObjectViewModel(ssObjects);
            this.solutionObjects = new ReadOnlyCollection <ISSObjectViewModel>(
                new SSObjectViewModel[]
            {
                rootItem
            });

            this.MessengerInstance.Register <ObjectTreeUpdated>(this, this.ObjectTreeUpdated);
        }
Ejemplo n.º 3
0
        private SSObjectViewModel(SSObject item, SSObjectViewModel parent)
        {
            this.item   = item;
            this.parent = parent;

            items = new ReadOnlyCollection <SSObjectViewModel>(
                (from thing in item.Items
                 select new SSObjectViewModel(thing, this))
                .ToList <SSObjectViewModel>());

            this.IsExpanded = true;
        }