예제 #1
0
        protected TreeViewItemViewModel(TreeViewItemViewModel parent, bool lazyLoadChildren)
            : this()
        {
            Parent = parent;
            _lazyLoadChildren = lazyLoadChildren;

            if (_lazyLoadChildren)
            {
                Children.Add(DummyChild);
            }

            if (Parent != null)
            {
                FailEvent = Parent.FailEvent;
                SuccessEvent = Parent.SuccessEvent;
            }
        }
예제 #2
0
 public SPContentTypeViewModel(SPClientContentType contentType, TreeViewItemViewModel parent)
     : this(parent, false)
 {
     if (contentType == null) throw new ArgumentNullException(nameof(contentType));
     _contentType = contentType;
 }
예제 #3
0
 /// <summary>
 ///     Initializes a new instance of the SiteItemViewModel class.
 /// </summary>
 protected SPContentTypeViewModel(TreeViewItemViewModel parent, bool lazyLoadChildren)
     : base(parent, lazyLoadChildren)
 {
 }
예제 #4
0
 public SPWebViewModel(SPClientWeb web, TreeViewItemViewModel parent)
     : this(parent, false)
 {
     if (web == null) throw new ArgumentNullException(nameof(web));
     Web = web;
 }
 /// <summary>
 ///     Initializes a new instance of the SiteItemViewModel class.
 /// </summary>
 public SPContextCollectionViewModel(TreeViewItemViewModel parent, bool lazyLoadChildren)
     : base(parent, lazyLoadChildren)
 {
 }
예제 #6
0
 public SPSiteViewModel(SPClientSite site, TreeViewItemViewModel parent)
     : this(parent, true)
 {
     if (site == null) throw new ArgumentNullException(nameof(site));
     _site = site;
 }
예제 #7
0
 /// <summary>
 ///     Initializes a new instance of the SiteItemViewModel class.
 /// </summary>
 protected SPFieldViewModel(TreeViewItemViewModel parent, bool lazyLoadChildren)
     : base(parent, lazyLoadChildren)
 {
 }
예제 #8
0
 public SPFieldViewModel(SPClientField field, TreeViewItemViewModel parent)
     : this(parent, false)
 {
     if (field == null) throw new ArgumentNullException(nameof(field));
     _field = field;
 }