Esempio n. 1
0
 void _newChildTreeNode(ITreeNode nTreeNode)
 {
     TreeNodeWidget treeNodeWidget_ = new TreeNodeWidget();
     treeNodeWidget_._setTreeNode(nTreeNode);
     nTreeNode._addTreeNode(treeNodeWidget_);
     this.Nodes.Add(treeNodeWidget_);
 }
Esempio n. 2
0
 public void _addTreeNode(ITreeNode nTreeNode)
 {
     mTreeNodes.Add(nTreeNode);
     if (null == mTreeView || mTreeView.IsDisposed)
     {
         return;
     }
     TreeNodeWidget treeNodeWidget_ = new TreeNodeWidget();
     treeNodeWidget_._setTreeNode(nTreeNode);
     nTreeNode._addTreeNode(treeNodeWidget_);
     mTreeView.Nodes.Add(treeNodeWidget_);
 }
Esempio n. 3
0
 public override void _initControl()
 {
     if (null == mTreeView || mTreeView.IsDisposed)
     {
         mTreeView = new System.Windows.Forms.TreeView();
         if (string.Compare(mDockStyle, @"Top") == 0)
         {
             mTreeView.Dock = DockStyle.Top;
         }
         else if (string.Compare(mDockStyle, @"Bottom") == 0)
         {
             mTreeView.Dock = DockStyle.Bottom;
         }
         else if (string.Compare(mDockStyle, @"Fill") == 0)
         {
             mTreeView.Dock = DockStyle.Fill;
         }
         else if (string.Compare(mDockStyle, @"Left") == 0)
         {
             mTreeView.Dock = DockStyle.Left;
         }
         else if (string.Compare(mDockStyle, @"Right") == 0)
         {
             mTreeView.Dock = DockStyle.Right;
         }
         else
         {
             mTreeView.Dock = DockStyle.None;
         }
         mTreeView.ShowRootLines = mShowRootLines;
         if (null != mSize)
         {
             mTreeView.Width = mSize._getWidth();
             mTreeView.Height = mSize._getHeight();
         }
         mTreeView.NodeMouseClick += this._nodeMouseClick;
         mTreeView.NodeMouseDoubleClick += this._nodeMouseDoubleClick;
         ImageSingleton imageSingleton_ = __singleton<ImageSingleton>._instance();
         mTreeView.ImageList = imageSingleton_._getImageList();
         if (null != mLoadCommand)
         {
             mLoadCommand._runCommand();
         }
         foreach (ITreeNode i in mTreeNodes)
         {
             TreeNodeWidget treeNodeWidget_ = new TreeNodeWidget();
             treeNodeWidget_._setTreeNode(i);
             i._addTreeNode(treeNodeWidget_);
             mTreeView.Nodes.Add(treeNodeWidget_);
         }
     }
 }