Ejemplo n.º 1
0
 public static TreeNode FromHandle(TreeView tree, IntPtr handle)
 {
     if (handle == IntPtr.Zero)
     {
         return(null);
     }
     // No arg checking on MS it just throws a NullRef if treeview is null
     return(tree.NodeFromHandle(handle));
 }
Ejemplo n.º 2
0
 /// <include file='doc\TreeNode.uex' path='docs/doc[@for="TreeNode.FromHandle"]/*' />
 /// <devdoc>
 ///     Returns a TreeNode object for the given HTREEITEM handle
 /// </devdoc>
 public static TreeNode FromHandle(TreeView tree, IntPtr handle) {
     // SECREVIEW:
     // Demand before we pass the TreeNode form handle.
     IntSecurity.ControlFromHandleOrLocation.Demand();
     return tree.NodeFromHandle(handle);
 }
Ejemplo n.º 3
0
		public static TreeNode FromHandle (TreeView tree, IntPtr handle)
		{
			if (handle == IntPtr.Zero)
				return null;
			// No arg checking on MS it just throws a NullRef if treeview is null
			return tree.NodeFromHandle (handle);
		}