]> CyberLeo.Net >> Repos - Github/sugarcrm.git/blob - jssource/src_files/include/ytree/TreeView/RootNode.js
Release 6.5.0
[Github/sugarcrm.git] / jssource / src_files / include / ytree / TreeView / RootNode.js
1 /* Copyright (c) 2006 Yahoo! Inc. All rights reserved. */
2
3 /**
4  * A custom YAHOO.widget.Node that handles the unique nature of 
5  * the virtual, presentationless root node.
6  *
7  * @extends YAHOO.widget.Node
8  * @constructor
9  */
10 YAHOO.widget.RootNode = function(oTree) {
11         // Initialize the node with null params.  The root node is a
12         // special case where the node has no presentation.  So we have
13         // to alter the standard properties a bit.
14         this.init(null, null, true);
15         
16         /**
17          * For the root node, we get the tree reference from as a param
18          * to the constructor instead of from the parent element.
19          *
20          * @type TreeView
21          */
22         this.tree = oTree;
23 };
24 YAHOO.widget.RootNode.prototype = new YAHOO.widget.Node();
25
26 // overrides YAHOO.widget.Node
27 YAHOO.widget.RootNode.prototype.getNodeHtml = function() { 
28         return ""; 
29 };
30