Upgrade to ExtJS 3.0.3 - Released 10/11/2009
[extjs.git] / docs / source / TreeNodeUI.html
index e1e86ed..160c1a1 100644 (file)
@@ -1,11 +1,17 @@
-<html>\r
-<head>\r
-  <title>The source code</title>\r
-    <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />\r
-    <script type="text/javascript" src="../resources/prettify/prettify.js"></script>\r
-</head>\r
-<body  onload="prettyPrint();">\r
-    <pre class="prettyprint lang-js"><div id="cls-Ext.tree.TreeNodeUI"></div>/**\r
+<html>
+<head>
+  <title>The source code</title>
+    <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />
+    <script type="text/javascript" src="../resources/prettify/prettify.js"></script>
+</head>
+<body  onload="prettyPrint();">
+    <pre class="prettyprint lang-js">/*!
+ * Ext JS Library 3.0.3
+ * Copyright(c) 2006-2009 Ext JS, LLC
+ * licensing@extjs.com
+ * http://www.extjs.com/license
+ */
+<div id="cls-Ext.tree.TreeNodeUI"></div>/**\r
  * @class Ext.tree.TreeNodeUI\r
  * This class provides the default UI implementation for Ext TreeNodes.\r
  * The TreeNode UI implementation is separate from the\r
@@ -135,10 +141,7 @@ Ext.tree.TreeNodeUI.prototype = {
         this.node.on("move", this.onMove, this);\r
 \r
         if(this.node.disabled){\r
-            this.addClass("x-tree-node-disabled");\r
-                       if (this.checkbox) {\r
-                               this.checkbox.disabled = true;\r
-                       }            \r
+            this.onDisableChange(this.node, true);            \r
         }\r
         if(this.node.hidden){\r
             this.hide();\r
@@ -223,13 +226,15 @@ Ext.tree.TreeNodeUI.prototype = {
         if(this.disabled){\r
             return;\r
         }\r
-        if(this.checkbox){\r
-            this.toggleCheck();\r
-        }\r
-        if(!this.animating && this.node.isExpandable()){\r
-            this.node.toggle();\r
+        if(this.fireEvent("beforedblclick", this.node, e) !== false){\r
+            if(this.checkbox){\r
+                this.toggleCheck();\r
+            }\r
+            if(!this.animating && this.node.isExpandable()){\r
+                this.node.toggle();\r
+            }\r
+            this.fireEvent("dblclick", this.node, e);\r
         }\r
-        this.fireEvent("dblclick", this.node, e);\r
     },\r
 \r
     onOver : function(e){\r
@@ -631,6 +636,6 @@ Ext.tree.RootTreeNodeUI = Ext.extend(Ext.tree.TreeNodeUI, {
     },\r
     collapse : Ext.emptyFn,\r
     expand : Ext.emptyFn\r
-});</pre>    \r
-</body>\r
+});</pre>
+</body>
 </html>
\ No newline at end of file